@@ -1193,11 +1193,11 @@ def _execute_child(self, args, executable, preexec_fn, close_fds,
11931193 try :
11941194 exc_type , exc_value = sys .exc_info ()[:2 ]
11951195 if isinstance (exc_value , OSError ):
1196- errno = exc_value .errno
1196+ errno_num = exc_value .errno
11971197 else :
1198- errno = 0
1198+ errno_num = 0
11991199 message = '%s:%x:%s' % (exc_type .__name__ ,
1200- errno , exc_value )
1200+ errno_num , exc_value )
12011201 message = message .encode (errors = "surrogatepass" )
12021202 os .write (errpipe_write , message )
12031203 except Exception :
@@ -1252,12 +1252,12 @@ def _execute_child(self, args, executable, preexec_fn, close_fds,
12521252 os .close (fd )
12531253 err_msg = err_msg .decode (errors = "surrogatepass" )
12541254 if issubclass (child_exception_type , OSError ) and hex_errno :
1255- errno = int (hex_errno , 16 )
1256- if errno != 0 :
1257- err_msg = os .strerror (errno )
1258- if errno == errno .ENOENT :
1255+ errno_num = int (hex_errno , 16 )
1256+ if errno_num != 0 :
1257+ err_msg = os .strerror (errno_num )
1258+ if errno_num == errno .ENOENT :
12591259 err_msg += ': ' + repr (args [0 ])
1260- raise child_exception_type (errno , err_msg )
1260+ raise child_exception_type (errno_num , err_msg )
12611261 raise child_exception_type (err_msg )
12621262
12631263
0 commit comments