aboutsummaryrefslogtreecommitdiff
path: root/sysdeps/posix
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>1999-08-20 23:44:23 +0000
committerUlrich Drepper <drepper@redhat.com>1999-08-20 23:44:23 +0000
commita2b3aa73b8ed0f264be82cd8700d00abd52999f4 (patch)
tree790f567de160ea8a8faabfaeb662c6a1ab989b0d /sysdeps/posix
parent6570e194e60822d81d6df31e260985e6a13b0f2a (diff)
downloadglibc-a2b3aa73b8ed0f264be82cd8700d00abd52999f4.tar
glibc-a2b3aa73b8ed0f264be82cd8700d00abd52999f4.tar.gz
glibc-a2b3aa73b8ed0f264be82cd8700d00abd52999f4.tar.bz2
glibc-a2b3aa73b8ed0f264be82cd8700d00abd52999f4.zip
Update.
* sysdeps/posix/getcwd.c: Correct comment saying < 0 is ok for size type. [PR libc/1269]
Diffstat (limited to 'sysdeps/posix')
-rw-r--r--sysdeps/posix/getcwd.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/sysdeps/posix/getcwd.c b/sysdeps/posix/getcwd.c
index e79598b045..617d340e4f 100644
--- a/sysdeps/posix/getcwd.c
+++ b/sysdeps/posix/getcwd.c
@@ -204,7 +204,7 @@ extern char *alloca ();
bytes of BUF. Returns NULL if the directory couldn't be determined or
SIZE was too small. If successful, returns BUF. In GNU, if BUF is
NULL, an array is allocated with `malloc'; the array is SIZE bytes long,
- unless SIZE <= 0, in which case it is as big as necessary. */
+ unless SIZE == 0, in which case it is as big as necessary. */
GETCWD_RETURN_TYPE
__getcwd (buf, size)
@@ -226,7 +226,7 @@ __getcwd (buf, size)
int prev_errno = errno;
size_t allocated = size;
- if (size <= 0)
+ if (size == 0)
{
if (buf != NULL)
{
@@ -363,7 +363,7 @@ __getcwd (buf, size)
if ((size_t) (pathp - path) <= namlen)
{
- if (size > 0)
+ if (size != 0)
{
(void) __closedir (dirstream);
__set_errno (ERANGE);