Files
amiga-libnix2/libnix/sources/nix/extra/mkdir.c
T
jshepher a99f123db5 Fixed missing function warnings.
Moved headers around so we include <devices/timer.h> before <sys/time.h>
(so we don't have to patch the OS headers)
2004-12-04 00:49:38 +00:00

23 lines
324 B
C
Executable File

#include <proto/dos.h>
#include <sys/types.h>
#include <sys/stat.h>
#include "stabs.h"
extern void __seterrno(void);
int mkdir(const char *name, mode_t mode)
{
BPTR fl;
int ret;
if ((fl=CreateDir((STRPTR)name)))
{
UnLock(fl); ret=chmod(name,mode);
}
else
{
__seterrno(); ret=-1;
}
return ret;
}