]> granicus.if.org Git - python/commitdiff
Restore a full arglist to the socket wrapper, so it supports keyword
authorTim Peters <tim.peters@gmail.com>
Wed, 31 Jul 2002 17:48:02 +0000 (17:48 +0000)
committerTim Peters <tim.peters@gmail.com>
Wed, 31 Jul 2002 17:48:02 +0000 (17:48 +0000)
arguments correctly too.

Lib/socket.py

index 7bb00a6a798f4cca22a84bd2c87d9f18daf9e2d7..515d47750444d6ff33b708e99ecf190e08cda79a 100644 (file)
@@ -62,8 +62,8 @@ if (sys.platform.lower().startswith("win")
 
     _realsocketcall = _socket.socket
 
-    def socket(*args):
-        return _socketobject(_realsocketcall(*args))
+    def socket(family=AF_INET, type=SOCK_STREAM, proto=0):
+        return _socketobject(_realsocketcall(family, type, proto))
     socket.__doc__ = _realsocketcall.__doc__
 
     if SSL_EXISTS: