Don't try to make files immutable (ie. chflags) before setting access times.
PR: 19973 Submitted by: Arjan de Vet <Arjan.deVet@adv.iae.nl> Reviewed by: Matthew Jacob <mjacob@feral.com>
This commit is contained in:
parent
e66b380285
commit
fddde8b056
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=63283
@ -631,8 +631,8 @@ setdirmodes(flags)
|
|||||||
cp = myname(ep);
|
cp = myname(ep);
|
||||||
(void) chown(cp, node.uid, node.gid);
|
(void) chown(cp, node.uid, node.gid);
|
||||||
(void) chmod(cp, node.mode);
|
(void) chmod(cp, node.mode);
|
||||||
(void) chflags(cp, node.flags);
|
|
||||||
utimes(cp, node.timep);
|
utimes(cp, node.timep);
|
||||||
|
(void) chflags(cp, node.flags);
|
||||||
ep->e_flags &= ~NEW;
|
ep->e_flags &= ~NEW;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -581,9 +581,9 @@ extractfile(name)
|
|||||||
}
|
}
|
||||||
(void) chown(name, curfile.dip->di_uid, curfile.dip->di_gid);
|
(void) chown(name, curfile.dip->di_uid, curfile.dip->di_gid);
|
||||||
(void) chmod(name, mode);
|
(void) chmod(name, mode);
|
||||||
|
utimes(name, timep);
|
||||||
(void) chflags(name, flags);
|
(void) chflags(name, flags);
|
||||||
skipfile();
|
skipfile();
|
||||||
utimes(name, timep);
|
|
||||||
return (GOOD);
|
return (GOOD);
|
||||||
|
|
||||||
case IFCHR:
|
case IFCHR:
|
||||||
@ -603,9 +603,9 @@ extractfile(name)
|
|||||||
}
|
}
|
||||||
(void) chown(name, curfile.dip->di_uid, curfile.dip->di_gid);
|
(void) chown(name, curfile.dip->di_uid, curfile.dip->di_gid);
|
||||||
(void) chmod(name, mode);
|
(void) chmod(name, mode);
|
||||||
|
utimes(name, timep);
|
||||||
(void) chflags(name, flags);
|
(void) chflags(name, flags);
|
||||||
skipfile();
|
skipfile();
|
||||||
utimes(name, timep);
|
|
||||||
return (GOOD);
|
return (GOOD);
|
||||||
|
|
||||||
case IFREG:
|
case IFREG:
|
||||||
@ -625,10 +625,10 @@ extractfile(name)
|
|||||||
}
|
}
|
||||||
(void) fchown(ofile, curfile.dip->di_uid, curfile.dip->di_gid);
|
(void) fchown(ofile, curfile.dip->di_uid, curfile.dip->di_gid);
|
||||||
(void) fchmod(ofile, mode);
|
(void) fchmod(ofile, mode);
|
||||||
(void) fchflags(ofile, flags);
|
|
||||||
getfile(xtrfile, xtrskip);
|
getfile(xtrfile, xtrskip);
|
||||||
(void) close(ofile);
|
(void) close(ofile);
|
||||||
utimes(name, timep);
|
utimes(name, timep);
|
||||||
|
(void) chflags(name, flags);
|
||||||
return (GOOD);
|
return (GOOD);
|
||||||
}
|
}
|
||||||
/* NOTREACHED */
|
/* NOTREACHED */
|
||||||
|
Loading…
Reference in New Issue
Block a user