diff options
| author | Charles.Forsyth <devnull@localhost> | 2009-05-21 20:02:52 +0000 |
|---|---|---|
| committer | Charles.Forsyth <devnull@localhost> | 2009-05-21 20:02:52 +0000 |
| commit | 04b29c1c92c3b38bc33bb1777400d00c0e2681a0 (patch) | |
| tree | 576eacf430d86eebe3c4f396a57525c03dabec16 /appl/cmd | |
| parent | af1b61f55a195350b4491438e8b2c381c4ba34bc (diff) | |
20090521-2101
Diffstat (limited to 'appl/cmd')
| -rw-r--r-- | appl/cmd/vacfs.b | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/appl/cmd/vacfs.b b/appl/cmd/vacfs.b index 5fffc98d..54e9b57b 100644 --- a/appl/cmd/vacfs.b +++ b/appl/cmd/vacfs.b @@ -158,6 +158,8 @@ walk(ed: ref Elem.Dir, name: string): (ref Elem, string) if(ne == nil) { nqid := childput(ed.qid, de.qid); ne = Elem.new(nqid, ed.vd, de, ed.qid); + if(ne == nil) + return (nil, sprint("%r")); set(ne); } return (ne, nil); @@ -204,14 +206,15 @@ init(nil: ref Draw->Context, args: list of string) styx = load Styx Styx->PATH; styxservers = load Styxservers Styxservers->PATH; vac = load Vac Vac->PATH; - if(venti == nil || vac == nil) - error("loading venti,vac"); - sys->pctl(sys->NEWPGRP, nil); venti->init(); vac->init(); styx->init(); styxservers->init(styx); + sys->pctl(sys->NEWPGRP, nil); + if(venti == nil || vac == nil) + error("loading venti,vac"); + arg->init(args); arg->setusage(arg->progname()+" [-Ddp] [-a addr] [[tag:]score]"); while((ch := arg->opt()) != 0) @@ -402,6 +405,10 @@ loop: if(ne == nil) { nqid := childput(ed.qid, de.qid); ne = Elem.new(nqid, ed.vd, de, ed.qid); + if(ne == nil) { + n.reply <-= (nil, sprint("%r")); + continue loop; + } } d := ne.stat(); ed.prev[ed.nprev++] = d; |
