work around mktemp warning
authorEvan Martin <martine@danga.com>
Sat, 8 Jan 2011 19:38:58 +0000 (11:38 -0800)
committerEvan Martin <martine@danga.com>
Sat, 8 Jan 2011 19:38:58 +0000 (11:38 -0800)
src/build_log_test.cc

index 11c0e09..ca268d2 100644 (file)
@@ -4,8 +4,7 @@
 
 struct BuildLogTest : public StateTestWithBuiltinRules {
   virtual void SetUp() {
-    char mktemp_template[] = "BuildLogTest-XXXXXX";
-    log_filename_ = mktemp(mktemp_template);
+    log_filename_ = tempnam(NULL, "ninja");
   }
   virtual void TearDown() {
     unlink(log_filename_.c_str());