| mark.bergman@thales-is.com 2007-06-08, 7:24 am |
| [Recently posted to comp.unix.programmer & comp.os.misc.linux with no
strong results]
I am porting from Digital Unix to Linux (RHEL 4), and am seeing a
difference in the return value of glob().
Given a non-existant directory "/tmp/a", and the following line of
code:
result = glob("/tmp/a", GLOB_ERR, NULL, &globInfo);
- result is set to GLOB_NOMATCH on both platforms.
However, if the first parameter is changed to "/tmp/a/*", i.e.
searching for files within the directory, the return value on Digital
Unix is still GLOB_NOMATCH, but on RHEL it is GLOB_ABORTED (2)
Which is correct?
(I have seen the man pages, and some Google matches mentioning
earlier
Linux bugs, but am still confused!)
TIA
Mark
|