From owner-freebsd-current Tue Nov 24 01:00:50 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id BAA25335 for freebsd-current-outgoing; Tue, 24 Nov 1998 01:00:50 -0800 (PST) (envelope-from owner-freebsd-current@FreeBSD.ORG) Received: from apollo.backplane.com (apollo.backplane.com [209.157.86.2]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id BAA25330 for ; Tue, 24 Nov 1998 01:00:49 -0800 (PST) (envelope-from dillon@apollo.backplane.com) Received: (from dillon@localhost) by apollo.backplane.com (8.9.1/8.9.1) id BAA13142; Tue, 24 Nov 1998 01:00:15 -0800 (PST) (envelope-from dillon) Date: Tue, 24 Nov 1998 01:00:15 -0800 (PST) From: Matthew Dillon Message-Id: <199811240900.BAA13142@apollo.backplane.com> To: Archie Cobbs Cc: bde@zeta.org.au (Bruce Evans), freebsd-current@FreeBSD.ORG, grog@lemis.com, rnordier@nordier.com Subject: Re: snprintf() in the kernel References: <199811240841.AAA03369@bubba.whistle.com> Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG : :Well, it's certainly easy enough to take them out.. however, some :are bug fixes... : :For example, if a function takes a string argument, when can you :assume an upper bound on how long the string is? :... I have a suggestion, why not split the problem up... commit the kernel snprintf() subroutine first, then put up a small subset of the snprintf() changes up for review and commit those on a fast track. i.e. get some of the more obvious sprintf() -> snprintf() fixes in and proven. *then*, after all of that is under our belts, we can start discussing more involved changes. This is much better then trying to throw everything at us in one big gulp. This sort of thing does not have to be an all-or-nothing proposition. Personally, I think we need to move to length-limited copies for all string operations. The code may be correct as is, and it may seem obvious to the people who wrote it, but FreeBSD is a collective effort and the more mistakes we can prevent in the future without compromising code effectiveness the better. -Matt ___________________________________________________________________________ :Archie Cobbs * Whistle Communications, Inc. * http://www.whistle.com : :To Unsubscribe: send mail to majordomo@FreeBSD.org :with "unsubscribe freebsd-current" in the body of the message : Matthew Dillon Engineering, HiWay Technologies, Inc. & BEST Internet Communications & God knows what else. (Please include original email in any response) To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message