mercurial/pure/osutil.py
changeset 27338 810337ae1b76
parent 25645 977102cb12fc
child 27474 e517a89c24e1
equal deleted inserted replaced
27337:9a17576103a4 27338:810337ae1b76
     2 #
     2 #
     3 #  Copyright 2009 Matt Mackall <mpm@selenic.com> and others
     3 #  Copyright 2009 Matt Mackall <mpm@selenic.com> and others
     4 #
     4 #
     5 # This software may be used and distributed according to the terms of the
     5 # This software may be used and distributed according to the terms of the
     6 # GNU General Public License version 2 or any later version.
     6 # GNU General Public License version 2 or any later version.
       
     7 
       
     8 from __future__ import absolute_import
     7 
     9 
     8 import os
    10 import os
     9 import stat as statmod
    11 import stat as statmod
    10 
    12 
    11 def _mode_to_kind(mode):
    13 def _mode_to_kind(mode):
    56     return result
    58     return result
    57 
    59 
    58 if os.name != 'nt':
    60 if os.name != 'nt':
    59     posixfile = open
    61     posixfile = open
    60 else:
    62 else:
    61     import ctypes, msvcrt
    63     import ctypes
       
    64     import msvcrt
    62 
    65 
    63     _kernel32 = ctypes.windll.kernel32
    66     _kernel32 = ctypes.windll.kernel32
    64 
    67 
    65     _DWORD = ctypes.c_ulong
    68     _DWORD = ctypes.c_ulong
    66     _LPCSTR = _LPSTR = ctypes.c_char_p
    69     _LPCSTR = _LPSTR = ctypes.c_char_p