Need a bool protection after all, to not hit a KASSERT
Details
Details
Diff Detail
Diff Detail
- Repository
- rG FreeBSD src repository
- Lint
Lint Not Applicable - Unit
Tests Not Applicable
Event Timeline
sys/netinet/tcp_hostcache.c | ||
---|---|---|
709 | Maybe add a comment why you are doing this dance. It wasn't obvious for us... |
sys/netinet/tcp_hostcache.c | ||
---|---|---|
711 | Not sure coordination is involved. Isn't it more that one should not call sbuf_drain() with an empty buffer. Please state that and finish the sentence with a full stop (.). |
Comment Actions
I would probably instead have changed sbuf_drain() to just return instead of asserting. Asserting made sense when it was a private implementation function, as a public API I think just returning instead of asserting is better behavior.