projects
/
pspp
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5e3f502
)
Fix braino: check S_ISLNK only if lstat succeeds.
author
Jim Meyering
<jim@meyering.net>
Sun, 24 May 1998 14:00:03 +0000
(14:00 +0000)
committer
Jim Meyering
<jim@meyering.net>
Sun, 24 May 1998 14:00:03 +0000
(14:00 +0000)
lib/lchown.c
patch
|
blob
|
history
diff --git
a/lib/lchown.c
b/lib/lchown.c
index 3e2b6c9f25a3f0eb77df6164af3a7900fbb16b80..0b1ebd8f2c7614411694d1de0b608d6f8b9953d1 100644
(file)
--- a/
lib/lchown.c
+++ b/
lib/lchown.c
@@
-34,7
+34,7
@@
lchown (const char *file, uid_t uid, gid_t gid)
{
struct stat stats;
- if (lstat (file, &stats) && S_ISLNK (stats.st_mode))
+ if (lstat (file, &stats)
== 0
&& S_ISLNK (stats.st_mode))
{
errno = ENOSYS;
return -1;