From ea173f505b0e87fe6af6d8e6b0f0e4d71e860cad Mon Sep 17 00:00:00 2001 From: Ulrich Drepper Date: Tue, 10 Mar 1998 11:13:09 +0000 Subject: [PATCH] (Reading/Closing Directory): Document readdir_r behaviour on EOD. --- manual/filesys.texi | 3 +++ 1 file changed, 3 insertions(+) diff --git a/manual/filesys.texi b/manual/filesys.texi index 889c083c12a..3a1e1f5bfc9 100644 --- a/manual/filesys.texi +++ b/manual/filesys.texi @@ -352,6 +352,9 @@ successfully. In this case a pointer to the result is returned in the function returns @code{-1}. The @code{errno} variable is set like described for @code{readdir}. +If there are no more directory entries, @code{readdir_r}'s return value is +@code{0}, and *@var{result} is set to @code{NULL}. + @strong{Portability Note:} On some systems, @code{readdir_r} may not return a terminated string as the file name even if no @code{d_reclen} element is available in @code{struct dirent} and the file name as the -- 2.47.2