mirror of
				https://github.com/python/cpython.git
				synced 2025-10-31 05:31:20 +00:00 
			
		
		
		
	socketserver renaming reversal part 3: move the module into the right
place and fix all references to it. Closes #2926.
This commit is contained in:
		
							parent
							
								
									6acb075f03
								
							
						
					
					
						commit
						e152a77d96
					
				
					 19 changed files with 409 additions and 411 deletions
				
			
		|  | @ -5,7 +5,7 @@ | |||
| has only one client per server, this was not a limitation. | ||||
| 
 | ||||
|    +---------------------------------+ +-------------+ | ||||
|    | socketserver.BaseRequestHandler | | SocketIO    | | ||||
|    | SocketServer.BaseRequestHandler | | SocketIO    | | ||||
|    +---------------------------------+ +-------------+ | ||||
|                    ^                   | register()  | | ||||
|                    |                   | unregister()| | ||||
|  | @ -31,7 +31,7 @@ | |||
| import os | ||||
| import socket | ||||
| import select | ||||
| import socketserver | ||||
| import SocketServer | ||||
| import struct | ||||
| import cPickle as pickle | ||||
| import threading | ||||
|  | @ -66,12 +66,12 @@ def pickle_code(co): | |||
| BUFSIZE = 8*1024 | ||||
| LOCALHOST = '127.0.0.1' | ||||
| 
 | ||||
| class RPCServer(socketserver.TCPServer): | ||||
| class RPCServer(SocketServer.TCPServer): | ||||
| 
 | ||||
|     def __init__(self, addr, handlerclass=None): | ||||
|         if handlerclass is None: | ||||
|             handlerclass = RPCHandler | ||||
|         socketserver.TCPServer.__init__(self, addr, handlerclass) | ||||
|         SocketServer.TCPServer.__init__(self, addr, handlerclass) | ||||
| 
 | ||||
|     def server_bind(self): | ||||
|         "Override TCPServer method, no bind() phase for connecting entity" | ||||
|  | @ -492,7 +492,7 @@ class RemoteProxy(object): | |||
|     def __init__(self, oid): | ||||
|         self.oid = oid | ||||
| 
 | ||||
| class RPCHandler(socketserver.BaseRequestHandler, SocketIO): | ||||
| class RPCHandler(SocketServer.BaseRequestHandler, SocketIO): | ||||
| 
 | ||||
|     debugging = False | ||||
|     location = "#S"  # Server | ||||
|  | @ -500,10 +500,10 @@ class RPCHandler(socketserver.BaseRequestHandler, SocketIO): | |||
|     def __init__(self, sock, addr, svr): | ||||
|         svr.current_handler = self ## cgt xxx | ||||
|         SocketIO.__init__(self, sock) | ||||
|         socketserver.BaseRequestHandler.__init__(self, sock, addr, svr) | ||||
|         SocketServer.BaseRequestHandler.__init__(self, sock, addr, svr) | ||||
| 
 | ||||
|     def handle(self): | ||||
|         "handle() method required by socketserver" | ||||
|         "handle() method required by SocketServer" | ||||
|         self.mainloop() | ||||
| 
 | ||||
|     def get_remote_proxy(self, oid): | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Georg Brandl
						Georg Brandl