diff options
author | cinap_lenrek <cinap_lenrek@gmx.de> | 2013-10-30 21:24:44 +0100 |
---|---|---|
committer | cinap_lenrek <cinap_lenrek@gmx.de> | 2013-10-30 21:24:44 +0100 |
commit | 7211fd7ce71de2347f3a00f1229ee1ac74b006e9 (patch) | |
tree | 38b07331cd154ecb0dce3606b001f8ecbc1661d4 | |
parent | 6d4e9f11b79148742198a8ec334d99053cb7cfce (diff) |
fix devshr related panic caused by Mount.to being nil (thanks mischief!)
the shr mount is linked into the Mhead with m->to initially nil. only
after the the server has been attached is m->to set. just check for
it in createdir().
-rw-r--r-- | sys/src/9/port/chan.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/src/9/port/chan.c b/sys/src/9/port/chan.c index a8bd9522a..c74fb5d51 100644 --- a/sys/src/9/port/chan.c +++ b/sys/src/9/port/chan.c @@ -1171,7 +1171,7 @@ createdir(Chan *c, Mhead *m) nexterror(); } for(f = m->mount; f; f = f->next){ - if(f->mflag&MCREATE){ + if(f->to != nil && (f->mflag&MCREATE) != 0){ nc = cclone(f->to); runlock(&m->lock); poperror(); |