lib9: add mode parameter to opentemp

This commit is contained in:
Russ Cox 2008-07-10 11:10:10 -04:00
parent c224dda84e
commit a58a827f2a
9 changed files with 23 additions and 34 deletions

View file

@ -260,7 +260,7 @@ threadmain(int argc, char **argv)
if(tmpnam == nil)
sysfatal("smprint: %r");
if((fd = opentemp(tmpnam)) < 0)
if((fd = opentemp(tmpnam, ORDWR|ORCLOSE)) < 0)
sysfatal("opentemp %s: %r", tmpnam);
if(statustime)
print("# %T reading scores into %s\n", tmpnam);