]> git.ipfire.org Git - thirdparty/ccache.git/commitdiff
refactor: Restructure code to help Clang-Tidy understand it
authorJoel Rosdahl <joel@rosdahl.net>
Mon, 21 Oct 2024 18:29:26 +0000 (20:29 +0200)
committerJoel Rosdahl <joel@rosdahl.net>
Tue, 22 Oct 2024 16:42:55 +0000 (18:42 +0200)
src/ccache/context.cpp

index 0f9fe0eeacfdbaabeeac76dbb9aaf6c4c2a4dd74..62650f981e7fd34029cb68de2a9eb666fee8b489 100644 (file)
@@ -67,8 +67,9 @@ Context::initialize(Args&& compiler_and_args,
   // initial configuration file. The intention is that all files and directories
   // in the cache directory should be affected by the configured umask and that
   // no other files and directories should.
-  if (config.umask()) {
-    original_umask = util::set_umask(*config.umask());
+  auto mask = config.umask();
+  if (mask) {
+    original_umask = util::set_umask(*mask);
   }
 }