Mercurial > hg
comparison mercurial/windows.py @ 15440:9ab2b3b730ee
windows: use umask 022 in debugstate output
debugstate would always report files as mode 666 or 777 on Windows.
umask is not used on Windows, but faking and using a defalt value of 022
matches what the test suite uses on Unix.
author | Mads Kiilerich <mads@kiilerich.com> |
---|---|
date | Mon, 07 Nov 2011 03:14:54 +0100 |
parents | 871c77e78f5d |
children | 25ea33fe7e5c |
comparison
equal
deleted
inserted
replaced
15439:01611e7c36ff | 15440:9ab2b3b730ee |
---|---|
24 termwidth = win32.termwidth | 24 termwidth = win32.termwidth |
25 testpid = win32.testpid | 25 testpid = win32.testpid |
26 unlink = win32.unlink | 26 unlink = win32.unlink |
27 | 27 |
28 nulldev = 'NUL:' | 28 nulldev = 'NUL:' |
29 umask = 002 | 29 umask = 0022 |
30 | 30 |
31 # wrap osutil.posixfile to provide friendlier exceptions | 31 # wrap osutil.posixfile to provide friendlier exceptions |
32 def posixfile(name, mode='r', buffering=-1): | 32 def posixfile(name, mode='r', buffering=-1): |
33 try: | 33 try: |
34 return osutil.posixfile(name, mode, buffering) | 34 return osutil.posixfile(name, mode, buffering) |