diff --git a/sys/src/cmd/sam/io.c b/sys/src/cmd/sam/io.c index f995bb7c9..a8ff31c31 100644 --- a/sys/src/cmd/sam/io.c +++ b/sys/src/cmd/sam/io.c @@ -66,7 +66,7 @@ writef(File *f) warn(Wnotnewline); closeio(n); if(f->name.s[0]==0 || samename){ - if(statfile(name, &dev, &qid, &mtime, 0, 0) > 0){ + if(statfile(genc, &dev, &qid, &mtime, 0, 0) > 0){ f->dev = dev; f->qidpath = qid; f->mtime = mtime;