shithub: namespace-example

ref: 48c2835479a9e2f1fee7d4a3240cb580bba7bc6e
dir: /main.c/

View raw version
#include <u.h>
#include <libc.h>
#include <fcall.h>
#include <thread.h>
#include <9p.h>

void
nattach(Req *r)
{
}

void
nread(Req *r)
{

}

void
nwrite(Req *r)
{
}

void 
nopen(Req *r)
{

}

void
nstat(Req *r)
{
}

void
ndestroyfid(Req *r){
}

Srv fs = {
	.attach = nattach,
	.walk1 = nwalk1,
	.open = nopen,
	.stat = nstat,
	.read = nread,
	.write = nwrite,
	
	.destroyfid = ndestroyfid,
}

void
threadmain(int argc, char **argv)
{
	print("This is a demo of namespace in plan9/9p /n");
	print("This is not meant for real world use and is just a simple demo /n");
	char *mtpt, *srvn;
	mtpt = "/mnt/namespace-test";
	srvn = nil;
}