summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJim Meyering <jim@meyering.net>2002-05-24 08:24:29 +0000
committerJim Meyering <jim@meyering.net>2002-05-24 08:24:29 +0000
commitf930c9ca0e46afdbdb1b82e5a245b3bb61ee4723 (patch)
tree4b0a390ca22de49e3bfd3c29b30e80899f9c457a
parent8e1915ff140b22081bf35551dcb9b99f118884c6 (diff)
downloadcoreutils-f930c9ca0e46afdbdb1b82e5a245b3bb61ee4723.tar.xz
(validate_path): Compare the result of the function --
not its (constant) address -- against zero.
-rw-r--r--src/pathchk.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/pathchk.c b/src/pathchk.c
index 39b939bdb..3722b438c 100644
--- a/src/pathchk.c
+++ b/src/pathchk.c
@@ -1,5 +1,5 @@
/* pathchk -- check whether pathnames are valid or portable
- Copyright (C) 1991-2001 Free Software Foundation, Inc.
+ Copyright (C) 1991-2002 Free Software Foundation, Inc.
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
@@ -325,7 +325,7 @@ validate_path (char *path, int portability)
if (!last_elem)
{
exists = dir_ok (path);
- if (dir_ok == 0)
+ if (exists == 0)
{
free (parent);
return 1;