'fopen' successfully opens directories
John W. Eaton
jwe at bevo.che.wisc.edu
Wed Apr 23 11:15:13 CDT 2008
On 23-Apr-2008, Sergei Steshenko wrote:
| Let's suppose the program works.
|
| If so, what useful can be done with 'fid' ?
|
| My point is that if I open a file, I can iterate over the FID using 'read' function
| and thus extracting item by item (minimally byte by byte) from the file.
|
| Likewise, if I open a directory using 'opendir', I can iterate over the directory handle
| using 'readdir' and thus extracting item by item (file or directory names) from the directory.
|
| I discovered this problem incidentally, not with /tmp, but rather forgetting to copy-paste
| part of path, i.e. I had /foo/bar instead of full /foo/bar/doo/dah/file.
|
| At least a friendly warning ...
If you (or anyone else) would like to see this behavior change, I
suggest submitting a patch.
jwe
More information about the Bug-octave
mailing list