mirror of
https://github.com/soypat/lneto.git
synced 2026-09-12 09:39:31 +00:00
Add round-robin implementation (#66)
* add handler.encapsulateNode * implement round robin handler approach * simplify round robin implementation * leave TODO * internet.node touch up * fix conflict resolve f-up * replace certain ErrShortBuffer with ErrTruncatedFrame error
This commit is contained in:
+1
-1
@@ -329,7 +329,7 @@ func (conn *Conn) Demux(buf []byte, off int) (err error) {
|
||||
conn.mu.Lock()
|
||||
defer conn.mu.Unlock()
|
||||
if off >= len(buf) {
|
||||
return lneto.ErrShortBuffer
|
||||
return lneto.ErrTruncatedFrame // TODO: this check is bad.
|
||||
}
|
||||
raddr, _, id, _, err := internal.GetIPAddr(buf[:off])
|
||||
if err != nil {
|
||||
|
||||
Reference in New Issue
Block a user