]> granicus.if.org Git - mutt/commitdiff
Include the user ID with temporary file names. Suggested by
authorThomas Roessler <roessler@does-not-exist.org>
Mon, 12 Apr 2004 19:17:32 +0000 (19:17 +0000)
committerThomas Roessler <roessler@does-not-exist.org>
Mon, 12 Apr 2004 19:17:32 +0000 (19:17 +0000)
eravin@panix.com in #1833.

muttlib.c

index 5f155147cbb1695503dd161e613d13ec42b2f1fd..e02b44dc0760a821f8a776f90b8dd5b0048db21b 100644 (file)
--- a/muttlib.c
+++ b/muttlib.c
@@ -657,7 +657,7 @@ void mutt_free_envelope (ENVELOPE **p)
 
 void _mutt_mktemp (char *s, const char *src, int line)
 {
-  snprintf (s, _POSIX_PATH_MAX, "%s/mutt-%s-%d-%d", NONULL (Tempdir), NONULL(Hostname), (int) getpid (), Counter++);
+  snprintf (s, _POSIX_PATH_MAX, "%s/mutt-%s-%d-%d-%d", NONULL (Tempdir), NONULL(Hostname), (int) getuid(), (int) getpid (), Counter++);
   dprint (1, (debugfile, "%s:%d: mutt_mktemp returns \"%s\".\n", src, line, s));
   unlink (s);
 }