OSDN Git Service

PR libstdc++/45924
[pf3gnuchains/gcc-fork.git] / libiberty / getcwd.c
index 8c7c04c..28f26eb 100644 (file)
@@ -3,13 +3,13 @@
 
 /*
 
-@deftypefn Supplemental char* getcwd (char *@var{pathname}, @var{len})
+@deftypefn Supplemental char* getcwd (char *@var{pathname}, int @var{len})
 
 Copy the absolute pathname for the current working directory into
 @var{pathname}, which is assumed to point to a buffer of at least
 @var{len} bytes, and return a pointer to the buffer.  If the current
 directory's path doesn't fit in @var{len} characters, the result is
-NULL and @var{errno} is set.  If @var{pathname} is a null pointer,
+@code{NULL} and @code{errno} is set.  If @var{pathname} is a null pointer,
 @code{getcwd} will obtain @var{len} bytes of space using
 @code{malloc}.
 
@@ -38,9 +38,7 @@ extern int errno;
 #endif
 
 char *
-getcwd (buf, len)
-  char *buf;
-  int len;
+getcwd (char *buf, size_t len)
 {
   char ourbuf[MAXPATHLEN];
   char *result;