docs/174023: [minor] getline(3) doc bug

Paul Procacci pprocacci at gmail.com
Fri Nov 30 20:40:00 UTC 2012


>Number:         174023
>Category:       docs
>Synopsis:       [minor] getline(3) doc bug
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-doc
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Fri Nov 30 20:40:00 UTC 2012
>Closed-Date:
>Last-Modified:
>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 at 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:
>Unformatted:


More information about the freebsd-doc mailing list