chown(8) and chgrp(1) directories once only

This commit is contained in:
Adam David 1996-08-14 18:13:58 +00:00
parent 477a3f5488
commit 7ba57172c1
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=17597

View File

@ -155,11 +155,10 @@ main(argc, argv)
for (rval = 0; (p = fts_read(ftsp)) != NULL;) {
switch (p->fts_info) {
case FTS_D:
if (Rflag) /* Change it at FTS_DP. */
continue;
fts_set(ftsp, p, FTS_SKIP);
break;
case FTS_D: /* Change it at FTS_DP. */
if (!Rflag)
fts_set(ftsp, p, FTS_SKIP);
continue;
case FTS_DNR: /* Warn, chown, continue. */
warnx("%s: %s", p->fts_path, strerror(p->fts_errno));
rval = 1;