Loading...
 
Skip to main content

Architecture / Installation


tempnam() leaves files in /tmp

I noticed every page access to my Tiki would leave an empty file in /tmp. I tracked this down to line 107 in tiki-setup.php, in TikiSetup::tempdir();

if (!$tempdir) {
$tempdir = dirnamefalse, ;
}

The file generated by tempnam() is obviously not removed. In my case, I simply "solved" this by always returning a static path for /tmp, but I'm guessing a "real" solution would involve cleaning this up (or use the /tmp configuration parameter ?).

Seems like you have half solved the problem already. There's already a bug logged for it on the SF site: #798550. I suggest that you add your findings to the bug report and hope it will help the developers to fix the problem.

Regards,

Pat.


The fix change;

$tempdir = dirname....

to

$tempfile = tempnam( false, '' );
$tempdir = dirname( $tempfile );
unlink( $tempfile );

I have update the cvs .. will get the bug fixed too.

Larry


Thanks Larry,

When you have updated the CVS with the bugfix then please also close the bug on SF. 😀

Regards.

Pat.