From owner-cvs-all Thu Aug 15 14:39:23 2002 Delivered-To: cvs-all@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 54A6637B405; Thu, 15 Aug 2002 14:39:13 -0700 (PDT) Received: from freefall.freebsd.org (freefall.FreeBSD.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 70ACB4413D; Thu, 15 Aug 2002 14:19:41 -0700 (PDT) (envelope-from robert@FreeBSD.org) Received: from freefall.freebsd.org (robert@localhost [127.0.0.1]) by freefall.freebsd.org (8.12.4/8.12.4) with ESMTP id g7FLJVJU017801; Thu, 15 Aug 2002 14:19:31 -0700 (PDT) (envelope-from robert@freefall.freebsd.org) Received: (from robert@localhost) by freefall.freebsd.org (8.12.4/8.12.4/Submit) id g7FLJVJc017800; Thu, 15 Aug 2002 14:19:31 -0700 (PDT) Message-Id: <200208152119.g7FLJVJc017800@freefall.freebsd.org> From: Robert Drehmel Date: Thu, 15 Aug 2002 14:19:31 -0700 (PDT) To: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: cvs commit: src/lib/libc/net inet_ntop.c X-FreeBSD-CVS-Branch: HEAD Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG robert 2002/08/15 14:19:31 PDT Modified files: lib/libc/net inet_ntop.c Log: - Fix a bug that wrote one char behind the end of the supplied buffer in case the size of it was equal to the number of characters the converted address consumed. The bug occurred when converting an AF_INET address. - Remove the SPRINTF macro and use sprintf instead. - Do not do string formatting using sprintf(3) and a temporary buffer which is copied when the supplied buffer provides enough space. Instead, use snprintf(3) and the real destination buffer, thus avoid the copy. Reported by: Stefan Farfeleder (1) PR: misc/41289 Revision Changes Path 1.11 +3 -6 src/lib/libc/net/inet_ntop.c To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message