]> git.ipfire.org Git - thirdparty/snapper.git/commitdiff
- set umask to prevent all-readable snapper.log
authorArvin Schnell <aschnell@suse.de>
Thu, 22 Sep 2011 14:16:58 +0000 (16:16 +0200)
committerArvin Schnell <aschnell@suse.de>
Thu, 22 Sep 2011 14:16:58 +0000 (16:16 +0200)
tools/snapper.cc

index 547fb0f454c7d02e11fdc9a8acf6c258d9c0ce0d..0cf09f8e5f5e13a8f0473f2538d53f0d18cc0ac1 100644 (file)
@@ -22,6 +22,8 @@
 
 #include <stdlib.h>
 #include <string.h>
+#include <sys/types.h>
+#include <sys/stat.h>
 #include <iostream>
 #include <boost/algorithm/string.hpp>
 
@@ -1028,6 +1030,8 @@ UndoCallbackImpl undo_callback_impl;
 int
 main(int argc, char** argv)
 {
+    umask(0027);
+
     setlocale(LC_ALL, "");
 
     initDefaultLogger();