osTempdir() bug
Status: Beta
Brought to you by:
render_man
I believe two cases are switched in os.cpp. I was getting a bad path because the TMP environment variable was not defined. I haven't checked the other OS cases.
--- src/common/os.cpp (revision 1174)
+++ src/common/os.cpp (working copy)
@@ -274,9 +274,9 @@
if (!tempDirEnv)
tempDirEnv = osEnvironment("TMP");
if (!tempDirEnv)
+ snprintf(result,resultsize,"PixieTemp_%d/",getpid());
+ else
snprintf(result,resultsize,"%s/PixieTemp_%d/",tempDirEnv,getpid());
- else
- snprintf(result,resultsize,"PixieTemp_%d/",getpid());
#endif
osFixSlashes(result);
Very true. The trunk is fixed.
Thank you,
Okan