]> git.rkrishnan.org Git - tahoe-lafs/tahoe-lafs.git/commitdiff
Fix umask again
authorDavid Stainton <dstainton415@gmail.com>
Tue, 8 Dec 2015 15:54:36 +0000 (17:54 +0200)
committerDaira Hopwood <daira@jacaranda.org>
Mon, 25 Jan 2016 15:54:28 +0000 (15:54 +0000)
src/allmydata/frontends/magic_folder.py

index 15ebf518aaff298210a752da4712c2a8d8c57cd3..8288ea6b6de7e9b774d70436ebb88f87354612fd 100644 (file)
@@ -485,8 +485,8 @@ class WriteFileMixin(object):
         # ensure parent directory exists
         head, tail = os.path.split(abspath_u)
 
+        old_mask = os.umask(self._umask)
         try:
-            old_mask = os.umask(self._umask)
             fileutil.make_dirs(head, (~ self._umask) & 0777)
             fileutil.write(replacement_path_u, file_contents)
         finally: