home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Geek Gadgets 1
/
ADE-1.bin
/
ade-dist
/
emacs-19.28-src.tgz
/
tar.out
/
fsf
/
emacs
/
unixlib
/
src
/
mkdir.c
< prev
next >
Wrap
C/C++ Source or Header
|
1996-09-28
|
426b
|
21 lines
#include "amiga.h"
#include <stdarg.h>
int mkdir(char *name, mode_t mode)
{
BPTR lock;
long amode;
chkabort();
if (lock = CreateDir(name))
{
UnLock(lock);
/* We remove script because mode 777 contains it by def, but it is
meaningless for directories */
amode = _make_protection(mode) & ~(FIBF_SCRIPT);
if (SetProtection(name, _make_protection(mode))) return 0;
}
ERROR;
}