touch: got to be owner if use date string
Dan_Jacobson at ATT.COM
Dan_Jacobson at ATT.COM
Thu Feb 14 10:37:05 AEST 1991
>>>>> On 12 Feb 91 21:30:24 GMT, jeq at i88.isc.com (Jonathan E. Quist) said:
J> touch() calls utime(file,0) to set the current time.
J> to set a particular time, it calls utime(file,&utimbuf),
J> with the contents of utimbuf set to the desired time.
J> The first requires only write permission; the second
J> requires ownership. (ref. utime(2))
OK, fine, than the touch man page should say
BUGS
The optional timestring doesn't work if you don't own the file,
even though you can write to it. In that case consider
copying the file, touching it to the preferred date, moving it
to the original file name, if possible, then chown(1) and
chgrp(1)ing the file to the original owner.
[I haven't considered any of the options letters.]
[Also thanks to Sam Ho]
--
Dan_Jacobson at ATT.COM Naperville IL USA +1 708-979-6364
More information about the Comp.bugs.sys5
mailing list