diff mercurial/pure/osutil.py @ 30639:d524c88511a7

py3: replace os.name with pycompat.osname (part 1 of 2) os.name returns unicodes on py3 and we have pycompat.osname which returns bytes. This series of 2 patches will change every ocurrence of os.name with pycompat.osname.
author Pulkit Goyal <7895pulkit@gmail.com>
date Mon, 19 Dec 2016 00:16:52 +0530
parents ba2c04059317
children e995f00a9e9a
line wrap: on
line diff
--- a/mercurial/pure/osutil.py	Sun Dec 18 02:08:59 2016 +0530
+++ b/mercurial/pure/osutil.py	Mon Dec 19 00:16:52 2016 +0530
@@ -159,7 +159,7 @@
 else:
     listdir = listdirpure
 
-if os.name != 'nt':
+if pycompat.osname != 'nt':
     posixfile = open
 
     _SCM_RIGHTS = 0x01