mirror of https://bitbucket.org/ausocean/av.git
Log packet size before la and ra.
This commit is contained in:
parent
fbad21bc76
commit
04ad1fec25
|
@ -399,7 +399,7 @@ func (pkt *packet) writeTo(c *Conn, queue bool) error {
|
|||
return nil
|
||||
}
|
||||
} else {
|
||||
// Send previously deferrd packet if combining it with the next one would exceed the chunk size.
|
||||
// Send previously deferred packet if combining it with the next one would exceed the chunk size.
|
||||
if len(c.deferred)+size+hSize > chunkSize {
|
||||
c.log(DebugLevel, pkg+"sending deferred packet separately", "size", len(c.deferred))
|
||||
_, err := c.write(c.deferred)
|
||||
|
@ -411,7 +411,7 @@ func (pkt *packet) writeTo(c *Conn, queue bool) error {
|
|||
}
|
||||
|
||||
// TODO(kortschak): Rewrite this horrific peice of premature optimisation.
|
||||
c.log(DebugLevel, pkg+"sending packet", "la", c.link.conn.LocalAddr(), "ra", c.link.conn.RemoteAddr(), "size", size)
|
||||
c.log(DebugLevel, pkg+"sending packet", "size", size, "la", c.link.conn.LocalAddr(), "ra", c.link.conn.RemoteAddr())
|
||||
for size+hSize != 0 {
|
||||
if chunkSize > size {
|
||||
chunkSize = size
|
||||
|
|
Loading…
Reference in New Issue