From 2495ce287fec516ad088ab9abedf41c0e6a98788 Mon Sep 17 00:00:00 2001 From: gdr-ftp Date: Sat, 11 Apr 1998 19:13:41 +0000 Subject: [PATCH] basename.3: dirname now returns "." instead of "" for arguments containing no directory components fgets.3: added a GNO note about streams opened in binary mode. --- usr.man/man3/basename.3 | 7 +++++-- usr.man/man3/fgets.3 | 14 ++++++++++++++ 2 files changed, 19 insertions(+), 2 deletions(-) diff --git a/usr.man/man3/basename.3 b/usr.man/man3/basename.3 index 6b677c5..f1a0013 100644 --- a/usr.man/man3/basename.3 +++ b/usr.man/man3/basename.3 @@ -1,9 +1,9 @@ .\" .\" Routines and man page by Devin Reade .\" -.\" $Id: basename.3,v 1.1 1997/02/27 07:32:21 gdr Exp $ +.\" $Id: basename.3,v 1.2 1998/04/11 19:13:41 gdr-ftp Exp $ .\" -.TH BASENAME 3 "26 November 1995" GNO "Library Routines" +.TH BASENAME 3 "29 March 1998" GNO "Library Routines" .SH NAME .BR basename , .BR dirname @@ -37,6 +37,9 @@ of not included in the resultant string. If .I path +contains no directory separator, then the string \fB"."\fR is returned. +If +.I path is NULL, an empty string is returned. .LP Unlike diff --git a/usr.man/man3/fgets.3 b/usr.man/man3/fgets.3 index 56d6ef9..f727154 100644 --- a/usr.man/man3/fgets.3 +++ b/usr.man/man3/fgets.3 @@ -128,6 +128,20 @@ may also fail and set .IR errno for any of the errors specified for the routine .BR getchar (3). +.SH GNO NOTES +If these routines are used on a stream which has been opened in binary +mode, the results may not be as is expected; this stdio implementation +has the assumption that the newline character is the linefeed (\\n). +Since a file opened in binary mode will usually, on the IIgs, use +carridge returns as the newline characters, the +.BR fgets +and +.BR gets +routines will return more characters than expected. +.I "This makes use of" +.B gets +.IR "particularly dangerous under GNO" +(see the section on BUGS, below). .SH SEE ALSO .BR feof (3), .BR ferror (3),