Deleted Added
full compact
subr_sbuf.c (103404) subr_sbuf.c (104449)
1/*-
2 * Copyright (c) 2000 Poul-Henning Kamp and Dag-Erling Co�dan Sm�rgrav
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 11 unchanged lines hidden (view full) ---

20 * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
21 * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
22 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
23 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
24 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
25 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
26 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27 *
1/*-
2 * Copyright (c) 2000 Poul-Henning Kamp and Dag-Erling Co�dan Sm�rgrav
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 11 unchanged lines hidden (view full) ---

20 * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
21 * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
22 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
23 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
24 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
25 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
26 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
27 *
28 * $FreeBSD: head/sys/kern/subr_sbuf.c 103404 2002-09-16 18:45:18Z phk $
28 * $FreeBSD: head/sys/kern/subr_sbuf.c 104449 2002-10-04 09:58:17Z phk $
29 */
30
31#include <sys/param.h>
32
33#ifdef _KERNEL
34#include <sys/ctype.h>
35#include <sys/kernel.h>
36#include <sys/malloc.h>

--- 516 unchanged lines hidden (view full) ---

553
554 if (SBUF_ISDYNAMIC(s))
555 SBFREE(s->s_buf);
556 isdyn = SBUF_ISDYNSTRUCT(s);
557 bzero(s, sizeof *s);
558 if (isdyn)
559 SBFREE(s);
560}
29 */
30
31#include <sys/param.h>
32
33#ifdef _KERNEL
34#include <sys/ctype.h>
35#include <sys/kernel.h>
36#include <sys/malloc.h>

--- 516 unchanged lines hidden (view full) ---

553
554 if (SBUF_ISDYNAMIC(s))
555 SBFREE(s->s_buf);
556 isdyn = SBUF_ISDYNSTRUCT(s);
557 bzero(s, sizeof *s);
558 if (isdyn)
559 SBFREE(s);
560}
561
562/*
563 * Check if an sbuf has been finished.
564 */
565int
566sbuf_done(struct sbuf *s)
567{
568
569 return(SBUF_ISFINISHED(s));
570}