From nobody@FreeBSD.org  Fri Nov 30 20:30:40 2012
Return-Path: <nobody@FreeBSD.org>
Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52])
	by hub.freebsd.org (Postfix) with ESMTP id 4E6DCDCC
	for <freebsd-gnats-submit@FreeBSD.org>; Fri, 30 Nov 2012 20:30:40 +0000 (UTC)
	(envelope-from nobody@FreeBSD.org)
Received: from red.freebsd.org (red.freebsd.org [IPv6:2001:4f8:fff6::22])
	by mx1.freebsd.org (Postfix) with ESMTP id 34FCB8FC08
	for <freebsd-gnats-submit@FreeBSD.org>; Fri, 30 Nov 2012 20:30:40 +0000 (UTC)
Received: from red.freebsd.org (localhost [127.0.0.1])
	by red.freebsd.org (8.14.5/8.14.5) with ESMTP id qAUKUeeK041467
	for <freebsd-gnats-submit@FreeBSD.org>; Fri, 30 Nov 2012 20:30:40 GMT
	(envelope-from nobody@red.freebsd.org)
Received: (from nobody@localhost)
	by red.freebsd.org (8.14.5/8.14.5/Submit) id qAUKUe9C041465;
	Fri, 30 Nov 2012 20:30:40 GMT
	(envelope-from nobody)
Message-Id: <201211302030.qAUKUe9C041465@red.freebsd.org>
Date: Fri, 30 Nov 2012 20:30:40 GMT
From: Paul Procacci <pprocacci@gmail.com>
To: freebsd-gnats-submit@FreeBSD.org
Subject: [minor] getline(3) doc bug
X-Send-Pr-Version: www-3.1
X-GNATS-Notify:

>Number:         174023
>Category:       docs
>Synopsis:       getline(3) doc bug
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    eadler
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Fri Nov 30 20:40:00 UTC 2012
>Closed-Date:    Sun Dec 09 04:15:54 UTC 2012
>Last-Modified:  Sun Dec 09 04:15:54 UTC 2012
>Originator:     Paul Procacci
>Release:        8.3-RELEASE-p4
>Organization:
>Environment:
FreeBSD nat.myhome 8.3-RELEASE-p3 FreeBSD 8.3-RELEASE-p3 #4: Fri Jun 29 14:59:00 CDT 2012     root@nat.myhome:/usr/obj/usr/src/sys/FIREWALL  i386

>Description:
Really minor documentation bug in getline(3).  (Major if you want to confuse someone - hehe).

In the "Return Values" section of the manpage it says the call to either the getline and getdelim functions return the value of the number of characters _written_.

Certainly this should have been _read_.
>How-To-Repeat:
man getline
>Fix:
diff -u lib/libc/stdio/getline.3.orig lib/libc/stdio/getline.3
--- lib/libc/stdio/getline.3.orig       2012-11-30 14:26:08.000000000 -0600
+++ lib/libc/stdio/getline.3    2012-11-30 14:26:16.000000000 -0600
@@ -76,7 +76,7 @@
 .Fn getdelim
 and
 .Fn getline
-functions return the number of characters written, excluding the
+functions return the number of characters read, excluding the
 terminating
 .Dv NUL
 character.

>Release-Note:
>Audit-Trail:
Responsible-Changed-From-To: freebsd-doc->eadler 
Responsible-Changed-By: eadler 
Responsible-Changed-When: Fri Nov 30 23:14:08 UTC 2012 
Responsible-Changed-Why:  
I'll take it. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=174023 
State-Changed-From-To: open->analyzed 
State-Changed-By: eadler 
State-Changed-When: Fri Nov 30 23:22:05 UTC 2012 
State-Changed-Why:  
awaiting approval or review prior to commit (no action needed from 
submitter) 

http://www.freebsd.org/cgi/query-pr.cgi?pr=174023 
State-Changed-From-To: analyzed->patched 
State-Changed-By: eadler 
State-Changed-When: Sat Dec 1 15:26:28 UTC 2012 
State-Changed-Why:  
committed varient in r243753 

http://www.freebsd.org/cgi/query-pr.cgi?pr=174023 
State-Changed-From-To: patched->closed 
State-Changed-By: eadler 
State-Changed-When: Sun Dec 9 04:15:53 UTC 2012 
State-Changed-Why:  
Committed. Thanks! 

http://www.freebsd.org/cgi/query-pr.cgi?pr=174023 
>Unformatted:
