mirror of
				https://github.com/python/cpython.git
				synced 2025-10-31 05:31:20 +00:00 
			
		
		
		
	[Bug #1525469] SimpleXMLRPCServer still uses the sys.exc_{value,type} module-level globals instead of calling sys.exc_info(). Reported by Russell Warren
This commit is contained in:
		
							parent
							
								
									a60b60e72e
								
							
						
					
					
						commit
						a5453c48d5
					
				
					 1 changed files with 4 additions and 2 deletions
				
			
		|  | @ -264,8 +264,9 @@ def _marshaled_dispatch(self, data, dispatch_method = None): | |||
|                                        encoding=self.encoding) | ||||
|         except: | ||||
|             # report exception back to server | ||||
|             exc_type, exc_value, exc_tb = sys.exc_info() | ||||
|             response = xmlrpclib.dumps( | ||||
|                 xmlrpclib.Fault(1, "%s:%s" % (sys.exc_type, sys.exc_value)), | ||||
|                 xmlrpclib.Fault(1, "%s:%s" % (exc_type, exc_value)), | ||||
|                 encoding=self.encoding, allow_none=self.allow_none, | ||||
|                 ) | ||||
| 
 | ||||
|  | @ -364,9 +365,10 @@ def system_multicall(self, call_list): | |||
|                      'faultString' : fault.faultString} | ||||
|                     ) | ||||
|             except: | ||||
|                 exc_type, exc_value, exc_tb = sys.exc_info() | ||||
|                 results.append( | ||||
|                     {'faultCode' : 1, | ||||
|                      'faultString' : "%s:%s" % (sys.exc_type, sys.exc_value)} | ||||
|                      'faultString' : "%s:%s" % (exc_type, exc_value)} | ||||
|                     ) | ||||
|         return results | ||||
| 
 | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Andrew M. Kuchling
						Andrew M. Kuchling