Mail Archives: djgpp-workers/1998/03/20/20:48:49
Indeed. New try follows. The reason I do like I do, is to make it easier
to add further errno improvments later (hint-hint, nudge).
Sigh,
MartinS
*** libc/posix/sys/stat/mkdir.c.org Sat Mar 21 02:02:35 1998
--- libc/posix/sys/stat/mkdir.c Sat Mar 21 02:33:54 1998
***************
*** 32,38 ****
--- 32,43 ----
/* see if the directory existed, in which case
we should return EEXIST - DJ */
if (access(dirname, D_OK) == 0)
+ {
errno = EEXIST;
+ return(-1);
+ }
+ /* Restore errno. */
+ errno = EACCES;
}
return -1;
}
- Raw text -