diff options
-rw-r--r-- | Lib/SocketServer.py | 23 |
1 files changed, 11 insertions, 12 deletions
diff --git a/Lib/SocketServer.py b/Lib/SocketServer.py index 15558f2..23f3a8e 100644 --- a/Lib/SocketServer.py +++ b/Lib/SocketServer.py @@ -273,18 +273,6 @@ class UDPServer(TCPServer): pass -if hasattr(socket, 'AF_UNIX'): - - class UnixStreamServer(TCPServer): - - address_family = socket.AF_UNIX - - - class UnixDatagramServer(UDPServer): - - address_family = socket.AF_UNIX - - class ForkingMixIn: """Mix-in class to handle each request in a new process.""" @@ -339,6 +327,17 @@ class ForkingTCPServer(ForkingMixIn, TCPServer): pass class ThreadingUDPServer(ThreadingMixIn, UDPServer): pass class ThreadingTCPServer(ThreadingMixIn, TCPServer): pass +if hasattr(socket, 'AF_UNIX'): + + class UnixStreamServer(TCPServer): + address_family = socket.AF_UNIX + + class UnixDatagramServer(UDPServer): + address_family = socket.AF_UNIX + + class ThreadingUnixStreamServer(ThreadingMixIn, UnixStreamServer): pass + + class ThreadingUnixDatagramServer(ThreadingMixIn, UnixDatagramServer): pass class BaseRequestHandler: |