From 3cd37427b5c5f26f62cff583fbde914467ddafe3 Mon Sep 17 00:00:00 2001 From: erik Date: Fri, 26 Jan 2007 21:43:58 +0000 Subject: Both files in this commit exhibit the wrong way to use temporary files. For TEHistory.cpp, it uses tmpfile() which produces a file which has a name that can be guessed. For vmemo.cpp, it uses tmpname() which only creates a predictable string. Both uses have been switched to using mkstemp() wrapped around umask(). This produces a much less predictable file that also has guaranteed restrictive permissions. I went a little farther in vmemo because it calls out to the shell using system to 'mv' the new file. That is kinda wasteful so I switched it to use rename instead. --- (limited to 'pics/console') -- cgit v0.9.0.2