toaruos/userspace/core/mkdir.c

27 lines
502 B
C
Raw Normal View History

/* This file is part of ToaruOS and is released under the terms
* of the NCSA / University of Illinois License - see LICENSE.md
* Copyright (C) 2013-2014 Kevin Lange
*/
2012-02-06 02:04:41 +04:00
/* vim:tabstop=4 shiftwidth=4 noexpandtab
*
* mkdir
*
* Create a directory.
2012-02-06 02:04:41 +04:00
*/
#include <stdio.h>
#include <stdint.h>
#include <sys/stat.h>
#include <sys/types.h>
2012-02-06 02:04:41 +04:00
int main(int argc, char ** argv) {
if (argc < 2) {
fprintf(stderr, "%s: expected argument\n", argv[0]);
return 1;
}
mkdir(argv[1], 0x00);
2012-02-06 02:04:41 +04:00
return 0;
}