Don't bail out if chmod(2) or chown(2) fails
Keep processing all the files specified.
This commit is contained in:
parent
b700d5a8ed
commit
f488547779
2
chmod.c
2
chmod.c
|
@ -77,7 +77,7 @@ chmodr(const char *path)
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
if(chmod(path, st.st_mode) == -1)
|
if(chmod(path, st.st_mode) == -1)
|
||||||
eprintf("chmod %s:", path);
|
weprintf("chmod %s:", path);
|
||||||
if(rflag)
|
if(rflag)
|
||||||
recurse(path, chmodr);
|
recurse(path, chmodr);
|
||||||
}
|
}
|
||||||
|
|
3
chown.c
3
chown.c
|
@ -70,8 +70,7 @@ chownpwgr(const char *path)
|
||||||
{
|
{
|
||||||
if(chown(path, pw ? pw->pw_uid : (uid_t)-1,
|
if(chown(path, pw ? pw->pw_uid : (uid_t)-1,
|
||||||
gr ? gr->gr_gid : (gid_t)-1) == -1)
|
gr ? gr->gr_gid : (gid_t)-1) == -1)
|
||||||
eprintf("chown %s:", path);
|
weprintf("chown %s:", path);
|
||||||
if(rflag)
|
if(rflag)
|
||||||
recurse(path, chownpwgr);
|
recurse(path, chownpwgr);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user