home *** CD-ROM | disk | FTP | other *** search
/ Usenet 1994 January / usenetsourcesnewsgroupsinfomagicjanuary1994.iso / sources / std_unix / mod.std.unix.v4 / text0012.txt < prev    next >
Encoding:
Internet Message Format  |  1987-06-30  |  3.3 KB

  1. Date: Wed, 11 Dec 85 17:52:17 EST
  2. From: Arnold Robbins <arnold%gatech.csnet@CSNET-RELAY.ARPA>
  3.  
  4. Chapter 5: Files, Directories, and File Systems
  5.  
  6. 5.2.2 Directory Operations
  7.  
  8. While I am very pleased to see the BSD style directory access routines
  9. included, I am dismayed at the lack of seekdir() and telldir(). These routines
  10. are essential for traversing directory subtrees when one has a limited number of
  11. open files allowed. Something should be done to try and included them.
  12.  
  13. ---------
  14.  
  15. 5.4.2.2. Description (of creat())
  16.  
  17.     ... If the file is a special file or a FIFO pipe, it is opened for
  18.     writing.
  19.  
  20. Should be ".. or a FIFO file...".
  21.  
  22.  
  23. A general note on _creat()_. It seems that whenever _open()_ is cited
  24. in the references, _creat()_ is not. Either all the references should
  25. be changed, or some note should be added explaining this. I don't think
  26. that just stating that
  27.  
  28.     creat (path, mode)
  29.  
  30. is equivalent to
  31.  
  32.     open (path, O_WRONLY | O_CREAT | O_TRUNC, mode);
  33.  
  34. is enough. (Of course, I could be wrong....)
  35.  
  36. [ I'd think establishing that identity should be sufficient.  -mod ]
  37.  
  38. -----------
  39.  
  40. 5.5.3.4 Errors (returned from mkfifo())
  41.  
  42. Why are EIO and ENFILE possible errors? EIO says "error writing to the
  43. file system". ENOSPC (couldn't extend the directory) should handle
  44. that. ENFILE seems to me to be wrong -- there is no reason to *open*
  45. the file in order to create the fifo. mkfifo should just make a
  46. directory entry and set the right bits in an inode (yeah I know, that
  47. is an implementation thing). The point is that no files should be
  48. opened here.
  49.  
  50. ---------
  51.  
  52. 5.6.2.4 Errors (for rmdir())
  53.  
  54.     [EBUSY]  The directory to be removed is the mount point for a
  55.          mounted file system.
  56.  
  57. What is a mounted file system? I thought that all references to such things
  58. had been removed.... This is probably just an oversight on the part of the
  59. editor(s).
  60.  
  61. -----------
  62.  
  63. 5.7.1.2 Description (of <stat.h>)
  64.  
  65.     S_IWXG    Read, write, and execute permissions for the group...
  66.  
  67. Should be S_IRWXG. This is undoubtedly a typo.
  68.  
  69.  
  70.     S_ISUID    .....
  71.         This bit shall be set only by the the function _chmod()_.
  72.         It should be cleared on any open for writing.
  73.  
  74.     The word "the" is printed twice in the actual document. I did not
  75. make a typo :-).  Also, I would prefer "It shall be cleared on any open for
  76. writing".
  77.  
  78.     S_ISGID
  79.  
  80. Same comment about "should" vs. "shall".
  81.  
  82. [ Seems like the reason was that that would outlaw some existing systems. -mod ]
  83.  
  84.     st_ctime
  85.  
  86. Why does the pipe() system call change this field?
  87.  
  88. -----------
  89.  
  90. 5.7.4.2 Description (of chmod())
  91.  
  92.     ... The value _chmod_ shall set the access permission portion of
  93.     the named file's mode according to the bit pattern contained in mode.
  94.  
  95. Delete the first two words of this sentence and capitalize "chmod".
  96.  
  97. [ We never capitalize anything which is really in lower case,
  98. even at the expense of filler words at the beginning of the sentence.  -mod ]
  99.  
  100. ----------
  101.  
  102. 5.7.5.2. Description (of chown())
  103.  
  104. Describes what happens to the setuid/setgid bits if successfully invoked
  105. by a non-superuser (they're cleared). All fine and good, but what happens to
  106. those bits if chown is invoked by the superuser? This should either be stated
  107. clearly or explicitly left undefined or implementation dependant.
  108.  
  109. ------------
  110.  
  111. 5.7.6.5 Notes (on utime())
  112.  
  113. What about st_ctime? Most Unix implementations (all?) do not allow this
  114. to be reset. Shouldn't something be said about it?
  115.  
  116. Volume-Number: Volume 4, Number 13
  117.  
  118.