Skip to content

Commit

Permalink
Replace <= with == since mtu cannot be negative
Browse files Browse the repository at this point in the history
MTU was changed to an unsigned integer
  • Loading branch information
wangzixiang authored and Sean-Der committed Nov 29, 2021
1 parent ed559dd commit 9c94cc0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions AUTHORS.txt
Original file line number Diff line number Diff line change
Expand Up @@ -31,4 +31,5 @@ Sean DuBois <seaduboi@amazon.com>
Sean DuBois <sean@siobud.com>
Simone Gotti <simone.gotti@gmail.com>
Tarrence van As <tarrence13@gmail.com>
wangzixiang <wangzixiang@onething.net>
Woodrow Douglass <wdouglass@carnegierobotics.com>
2 changes: 1 addition & 1 deletion codecs/g711_packet.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ type G711Payloader struct{}
// Payload fragments an G711 packet across one or more byte arrays
func (p *G711Payloader) Payload(mtu uint16, payload []byte) [][]byte {
var out [][]byte
if payload == nil || mtu <= 0 {
if payload == nil || mtu == 0 {
return out
}

Expand Down

0 comments on commit 9c94cc0

Please sign in to comment.