home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 January / usenetsourcesnewsgroupsinfomagicjanuary1994.iso / sources / std_unix / v21 / 090 / text0000.txt < prev   
Encoding:
Internet Message Format  |  1990-12-05  |  717 b 

  1. From:  cowan@marob.masa.com (John Cowan)
  2.  
  3. In article <490@usenix.ORG> caywood@teb.larc.nasa.gov (John Caywood) writes:
  4. >I take this to mean that, no, cp doesn't unlink an existing file, but
  5. >it truncates it upon opening under these conditions.  Consequently,
  6. >yes, djm is correct, cp doesn't unlink.  I don't understand, though,
  7. >why opening with O_TRUNC isn't equivalent.
  8.  
  9. The difference between unlinking before opening and opening with O_TRUNC is,
  10. of course, that the former course of action can change the file's owner,
  11. group, and mode settings, whereas the latter course of action cannot.
  12. -- 
  13. cowan@marob.masa.com            (aka ...!hombre!marob!cowan)
  14.             e'osai ko sarji la lojban
  15.  
  16. Volume-Number: Volume 21, Number 90
  17.  
  18.