mercurial/transaction.py
changeset 6065 53ed9b40cfc4
parent 5865 e7127f669edb
child 6441 c9b8f2820bc0
--- a/mercurial/transaction.py	Sat Feb 09 18:38:54 2008 -0200
+++ b/mercurial/transaction.py	Sat Feb 09 18:38:54 2008 -0200
@@ -15,7 +15,7 @@
 import os
 
 class transaction(object):
-    def __init__(self, report, opener, journal, after=None):
+    def __init__(self, report, opener, journal, after=None, createmode=None):
         self.journal = None
 
         self.count = 1
@@ -27,6 +27,8 @@
         self.journal = journal
 
         self.file = open(self.journal, "w")
+        if createmode is not None:
+            os.chmod(self.journal, createmode & 0666)
 
     def __del__(self):
         if self.journal: