From 6fd70b7218fafa115717ffcbeb9b7ccfc3474369 Mon Sep 17 00:00:00 2001 From: Bryan Drewery Date: Sun, 7 Nov 2004 21:37:15 +0000 Subject: [PATCH] * fchmod() to avoid a race condition svn: 1349 --- src/misc_file.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/misc_file.c b/src/misc_file.c index 6b9b3f601..b930f6bce 100755 --- a/src/misc_file.c +++ b/src/misc_file.c @@ -180,7 +180,7 @@ void Tempfile::MakeTemp() if ((f = fdopen(fd, "w+b")) == NULL) goto error; - chmod(file, S_IRUSR | S_IWUSR); + fchmod(fd, S_IRUSR | S_IWUSR); return;