@@ -356,7 +356,7 @@ class Popen(args, bufsize=-1, executable=None,
356356"""
357357
358358import sys
359- mswindows = (sys .platform == "win32" )
359+ _mswindows = (sys .platform == "win32" )
360360
361361import io
362362import os
@@ -399,7 +399,7 @@ def __str__(self):
399399 (self .cmd , self .timeout ))
400400
401401
402- if mswindows :
402+ if _mswindows :
403403 import threading
404404 import msvcrt
405405 import _winapi
@@ -438,7 +438,7 @@ class STARTUPINFO:
438438 # NOTE: We intentionally exclude list2cmdline as it is
439439 # considered an internal implementation detail. issue10838.
440440
441- if mswindows :
441+ if _mswindows :
442442 from _winapi import (CREATE_NEW_CONSOLE , CREATE_NEW_PROCESS_GROUP ,
443443 STD_INPUT_HANDLE , STD_OUTPUT_HANDLE ,
444444 STD_ERROR_HANDLE , SW_HIDE ,
@@ -765,7 +765,7 @@ def __init__(self, args, bufsize=-1, executable=None,
765765 if not isinstance (bufsize , int ):
766766 raise TypeError ("bufsize must be an integer" )
767767
768- if mswindows :
768+ if _mswindows :
769769 if preexec_fn is not None :
770770 raise ValueError ("preexec_fn is not supported on Windows "
771771 "platforms" )
@@ -825,7 +825,7 @@ def __init__(self, args, bufsize=-1, executable=None,
825825 # quickly terminating child could make our fds unwrappable
826826 # (see #8458).
827827
828- if mswindows :
828+ if _mswindows :
829829 if p2cwrite != - 1 :
830830 p2cwrite = msvcrt .open_osfhandle (p2cwrite .Detach (), 0 )
831831 if c2pread != - 1 :
@@ -1002,7 +1002,7 @@ def _check_timeout(self, endtime, orig_timeout):
10021002 raise TimeoutExpired (self .args , orig_timeout )
10031003
10041004
1005- if mswindows :
1005+ if _mswindows :
10061006 #
10071007 # Windows methods
10081008 #
0 commit comments