git: getline.3: Note to distinguish between error and EoF

Aaron LI aly at crater.dragonflybsd.org
Wed Jan 16 02:14:52 PST 2019


commit 45e55a3219a7a8f2adabfdf399af71f059cfc763
Author: Aaron LI <aly at aaronly.me>
Date:   Wed Jan 16 16:51:41 2019 +0800

    getline.3: Note to distinguish between error and EoF
    
    Note that the getline() and getdelim() functions do not distinguish
    between end-of-file and error, so the callers must use feof() or
    ferror() to determine which occurred.
    
    Update the example to check the error.
    
    Obtained-from: OpenBSD

Summary of changes:
 lib/libc/stdio/getline.3 | 14 +++++++++++++-
 1 file changed, 13 insertions(+), 1 deletion(-)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/45e55a3219a7a8f2adabfdf399af71f059cfc763


-- 
DragonFly BSD source repository



More information about the Commits mailing list