From owner-freebsd-doc@FreeBSD.ORG Wed Jun 22 03:00:40 2005 Return-Path: X-Original-To: freebsd-doc@hub.freebsd.org Delivered-To: freebsd-doc@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6A8D516A41C for ; Wed, 22 Jun 2005 03:00:40 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3000343D48 for ; Wed, 22 Jun 2005 03:00:40 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.3/8.13.3) with ESMTP id j5M30eNp043971 for ; Wed, 22 Jun 2005 03:00:40 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.13.3/8.13.1/Submit) id j5M30eug043970; Wed, 22 Jun 2005 03:00:40 GMT (envelope-from gnats) Resent-Date: Wed, 22 Jun 2005 03:00:40 GMT Resent-Message-Id: <200506220300.j5M30eug043970@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-doc@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Vlad Skvortsov Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 269CA16A41C for ; Wed, 22 Jun 2005 02:51:13 +0000 (GMT) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (www.freebsd.org [216.136.204.117]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1504143D1F for ; Wed, 22 Jun 2005 02:51:13 +0000 (GMT) (envelope-from nobody@FreeBSD.org) Received: from www.freebsd.org (localhost [127.0.0.1]) by www.freebsd.org (8.13.1/8.13.1) with ESMTP id j5M2p2sl022893 for ; Wed, 22 Jun 2005 02:51:02 GMT (envelope-from nobody@www.freebsd.org) Received: (from nobody@localhost) by www.freebsd.org (8.13.1/8.13.1/Submit) id j5M2p1UX022891; Wed, 22 Jun 2005 02:51:01 GMT (envelope-from nobody) Message-Id: <200506220251.j5M2p1UX022891@www.freebsd.org> Date: Wed, 22 Jun 2005 02:51:01 GMT From: Vlad Skvortsov To: freebsd-gnats-submit@FreeBSD.org X-Send-Pr-Version: www-2.3 Cc: Subject: docs/82508: misleading man page for basename/dirname X-BeenThere: freebsd-doc@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Documentation project List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 22 Jun 2005 03:00:40 -0000 >Number: 82508 >Category: docs >Synopsis: misleading man page for basename/dirname >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-doc >State: open >Quarter: >Keywords: >Date-Required: >Class: doc-bug >Submitter-Id: current-users >Arrival-Date: Wed Jun 22 03:00:39 GMT 2005 >Closed-Date: >Last-Modified: >Originator: Vlad Skvortsov >Release: 5.2.1 >Organization: Netli, Inc. >Environment: FreeBSD vlad.hq.netli.lan 5.2.1-RELEASE FreeBSD 5.2.1-RELEASE #0: Sat May 22 11:32:00 PDT 2004 root@vlad.hq.netli.lan:/usr/obj/usr/src/sys/VLAD i386 >Description: The man pages for both basename(3) and dirname(3) state that the functions return pointers to the internal _static_ storage. However, those functions actually perform malloc() call to allocate storage on the first invocation. Thus, the memory pointer returned is actually a pointer to internal but dynamically allocated storage. I don't know whether this violates standard or not, but the documentation is misleading. >How-To-Repeat: Not applicable. >Fix: Fix the docs. >Release-Note: >Audit-Trail: >Unformatted: