source: testjes/testmkdir.cpp @ 10

Last change on this file since 10 was 10, checked in by willem, 11 years ago

willem

File size: 428 bytes
Line 
1// g++ testmkdir.cpp ../trunk/wutils.cpp -I ../trunk
2#include <wutils.h>
3#include <stdio.h>
4#include <sys/types.h>
5#include <iostream>
6void doit(std::string d,mode_t mode)
7{
8  std::cout << d << " " << mode << " " <<mkdir_p(d,mode) << std::endl;
9}
10int main()
11{
12  int rc;
13  doit("aap",0700);
14  doit("aap/noot/",0700);
15  doit("/tmp/aan/noot/",0700);
16  doit("/tmp/aap/mies",0700);
17  doit ("",0700);
18  doit ("/",0700);
19  return 0;
20}
Note: See TracBrowser for help on using the repository browser.