diff options
author | Russ Cox <rsc@swtch.com> | 2008-05-05 23:07:54 -0400 |
---|---|---|
committer | Russ Cox <rsc@swtch.com> | 2008-05-05 23:07:54 -0400 |
commit | 118dfa98b81785213b819f66cdb92e5a43f62326 (patch) | |
tree | dee2a68ea379b85eb7bfcdd98a07b53b0531a565 /src/lib9p | |
parent | ce1e3a796ccce89dd284dab916ec5b83a03fdcf8 (diff) | |
download | plan9port-118dfa98b81785213b819f66cdb92e5a43f62326.tar.gz plan9port-118dfa98b81785213b819f66cdb92e5a43f62326.tar.bz2 plan9port-118dfa98b81785213b819f66cdb92e5a43f62326.zip |
post9pservice: accept mtpt (via fuse)
Diffstat (limited to 'src/lib9p')
-rw-r--r-- | src/lib9p/tpost.c | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/src/lib9p/tpost.c b/src/lib9p/tpost.c index 337d2544..45426f12 100644 --- a/src/lib9p/tpost.c +++ b/src/lib9p/tpost.c @@ -14,9 +14,8 @@ void threadpostmountsrv(Srv *s, char *name, char *mtpt, int flag) { int fd[2]; - - if(mtpt) - sysfatal("mount not supported"); + int mtfd; + char *addr; if(!s->nopipe){ if(pipe(fd) < 0) @@ -24,7 +23,10 @@ threadpostmountsrv(Srv *s, char *name, char *mtpt, int flag) s->infd = s->outfd = fd[1]; s->srvfd = fd[0]; } - if(name && post9pservice(s->srvfd, name) < 0) - sysfatal("post9pservice %s: %r", name); + if(name || mtpt){ + if(post9pservice(s->srvfd, name, mtpt) < 0) + sysfatal("post9pservice %s: %r", name); + }else if(!s->nopipe) + sysfatal("no one to serve"); proccreate(launchsrv, s, 32*1024); } |