diff options
author | des <des@FreeBSD.org> | 2001-01-28 00:33:58 +0000 |
---|---|---|
committer | des <des@FreeBSD.org> | 2001-01-28 00:33:58 +0000 |
commit | f175b29e06aee5787c55ef79b2cfd76f3d7a4c1f (patch) | |
tree | a840b6b388b556beb4c1ee66f71cbfafead2c3bd /sys/kern | |
parent | ca14441dcbca8cc07a22816f87c59338a566065b (diff) | |
download | FreeBSD-src-f175b29e06aee5787c55ef79b2cfd76f3d7a4c1f.zip FreeBSD-src-f175b29e06aee5787c55ef79b2cfd76f3d7a4c1f.tar.gz |
Remove an assertion I forgot to remove in the previous commit: sbuf_len()
may now be called with an unfinished sbuf.
For consistency, copy the related comment from sbuf_delete() to sbuf_clear()
and sbuf_len().
Diffstat (limited to 'sys/kern')
-rw-r--r-- | sys/kern/subr_sbuf.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sys/kern/subr_sbuf.c b/sys/kern/subr_sbuf.c index c59cea7..247ecac 100644 --- a/sys/kern/subr_sbuf.c +++ b/sys/kern/subr_sbuf.c @@ -114,6 +114,7 @@ void sbuf_clear(struct sbuf *s) { assert_sbuf_integrity(s); + /* don't care if it's finished or not */ SBUF_CLEARFLAG(s, SBUF_FINISHED); SBUF_CLEARFLAG(s, SBUF_OVERFLOWED); @@ -285,7 +286,7 @@ int sbuf_len(struct sbuf *s) { assert_sbuf_integrity(s); - assert_sbuf_state(s, SBUF_FINISHED); + /* don't care if it's finished or not */ if (SBUF_HASOVERFLOWED(s)) return (-1); |