diff options
author | rsc <devnull@localhost> | 2004-03-21 04:33:13 +0000 |
---|---|---|
committer | rsc <devnull@localhost> | 2004-03-21 04:33:13 +0000 |
commit | 2277c5d7bbe1f9595fad512d8f790708473a9bf1 (patch) | |
tree | 4d653e13906f1971d3170dba6dbe0fbf92eb48d6 /src/lib9p/ftest.c | |
parent | a770daa795754cb600ad3fab2fdd2961147006c4 (diff) | |
download | plan9port-2277c5d7bbe1f9595fad512d8f790708473a9bf1.tar.gz plan9port-2277c5d7bbe1f9595fad512d8f790708473a9bf1.tar.bz2 plan9port-2277c5d7bbe1f9595fad512d8f790708473a9bf1.zip |
Small tweaks
Lots of new code imported.
Diffstat (limited to 'src/lib9p/ftest.c')
-rw-r--r-- | src/lib9p/ftest.c | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/src/lib9p/ftest.c b/src/lib9p/ftest.c new file mode 100644 index 00000000..6692b7f1 --- /dev/null +++ b/src/lib9p/ftest.c @@ -0,0 +1,29 @@ +#include <u.h> +#include <libc.h> +#include <auth.h> +#include <fcall.h> +#include "9p.h" + +void +main(void) +{ + Tree *t; + File *hello, *goodbye, *world; + + t = mktree(); + + hello = fcreate(t->root, "hello", CHDIR|0777); + assert(hello != nil); + + goodbye = fcreate(t->root, "goodbye", CHDIR|0777); + assert(goodbye != nil); + + world = fcreate(hello, "world", 0666); + assert(world != nil); + world = fcreate(goodbye, "world", 0666); + assert(world != nil); + fdump(t->root, 0); + + fremove(world); + fdump(t->root, 0); +} |