Skip to content

Commit

Permalink
Return 0 written bytes on write error
Browse files Browse the repository at this point in the history
Return 0 written bytes on write error
  • Loading branch information
cnderrauber committed Dec 10, 2024
1 parent abb6bea commit 29c46e2
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions stream.go
Original file line number Diff line number Diff line change
Expand Up @@ -291,6 +291,7 @@ func (s *Stream) WriteSCTP(p []byte, ppi PayloadProtocolIdentifier) (int, error)
s.sequenceNumber--
}
s.lock.Unlock()
n = 0
}
if s.association.isBlockWrite() {
s.writeLock.Unlock()
Expand Down

0 comments on commit 29c46e2

Please sign in to comment.