[PATCH] recreate /tmp/mc-$USER if it is deleted.

Denis Vlasenko vda.linux at googlemail.com
Fri May 18 12:04:16 UTC 2007


Hi mc-devel,

I am running a script which deletes ordinary files and directories in
/tmp if they are older than $THRESHOLD seconds. mc falls victim to it:
if I have mc running for days, /tmp/mc-$USER gets deleted and mc
complains that it cannot create temporary files when I, for example,
try to enter a .tar.gz.

The fix is very non-intrusive and cheap (just an extra lstat). See
attached patch. Run tested.
--
vda
-------------- next part --------------
A non-text attachment was scrubbed...
Name: mc_recreate_tempdir.diff
Type: application/octet-stream
Size: 554 bytes
Desc: not available
URL: <http://lists.midnight-commander.org/pipermail/mc-devel/attachments/20070518/8781ee64/attachment.obj>


More information about the mc-devel mailing list