From owner-freebsd-arch Mon Dec 11 23:35:55 2000 From owner-freebsd-arch@FreeBSD.ORG Mon Dec 11 23:35:54 2000 Return-Path: Delivered-To: freebsd-arch@freebsd.org Received: from critter.freebsd.dk (flutter.freebsd.dk [212.242.40.147]) by hub.freebsd.org (Postfix) with ESMTP id 3ED2A37B400 for ; Mon, 11 Dec 2000 23:35:53 -0800 (PST) Received: from critter (localhost [127.0.0.1]) by critter.freebsd.dk (8.11.1/8.11.1) with ESMTP id eBC7ZhL18371; Tue, 12 Dec 2000 08:35:43 +0100 (CET) (envelope-from phk@critter.freebsd.dk) To: Peter Jeremy Cc: Dag-Erling Smorgrav , arch@FreeBSD.ORG Subject: Re: Safe string formatting in the kernel In-Reply-To: Your message of "Tue, 12 Dec 2000 14:19:58 +1100." <20001212141958.P69646@gsmx07.alcatel.com.au> Date: Tue, 12 Dec 2000 08:35:43 +0100 Message-ID: <18369.976606543@critter> From: Poul-Henning Kamp Sender: owner-freebsd-arch@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG In message <20001212141958.P69646@gsmx07.alcatel.com.au>, Peter Jeremy writes: >On 2000-Dec-11 20:13:24 +0100, Dag-Erling Smorgrav wrote: >> http://people.freebsd.org/~des/software/sbuf-20001211b.diff > >Overall the purpose of this isn't clear to me. It doesn't appear to >have any real advantages over using the standard string functions. >The main advantage I can see for having a proper set of string >functions would be to support dynamic (growable) strings and sbuf uses a >fixed size buffer. The fixed size buffer is just to keep the initial implementation simple I think. Growable buffers is indeed catered for in the API (that's why the sbuf_finish() function is there. -- Poul-Henning Kamp | UNIX since Zilog Zeus 3.20 phk@FreeBSD.ORG | TCP/IP since RFC 956 FreeBSD committer | BSD since 4.3-tahoe Never attribute to malice what can adequately be explained by incompetence. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-arch" in the body of the message