]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
small fixes
authorGuido van Rossum <guido@python.org>
Wed, 4 Oct 1995 18:39:03 +0000 (18:39 +0000)
committerGuido van Rossum <guido@python.org>
Wed, 4 Oct 1995 18:39:03 +0000 (18:39 +0000)
Demo/rpc/rpc.py
Demo/rpc/xdr.py

index fb21fc2f98c43a64749180251ffe707ed3d5b33e..83cc954b3d976ae361c88748670fa3e76ecd7d8c 100644 (file)
@@ -376,7 +376,7 @@ class RawBroadcastUDPClient(RawUDPClient):
 
        def connsocket(self):
                # Don't connect -- use sendto
-               self.sock.allowbroadcast(1)
+               self.sock.setsockopt(socket.SOL_SOCKET, socket.SO_BROADCAST, 1)
 
        def set_reply_handler(self, reply_handler):
                self.reply_handler = reply_handler
index 0c5185ee88073cdbed90c3becbad6a01121f3797..109d2f94680c1f66d0be177e2454da3400818a33 100644 (file)
@@ -69,7 +69,7 @@ class Packer:
                self.pack_uint(n)
                self.pack_fstring(n, s)
 
-       pack_opaque = pack_string
+       pack_opaque = pack_fopaque
 
        def pack_list(self, list, pack_item):
                for item in list:
@@ -86,7 +86,7 @@ class Packer:
        def pack_array(self, list, pack_item):
                n = len(list)
                self.pack_uint(n)
-               self.pack_farray(n, list)
+               self.pack_farray(n, list, pack_item)
 
 
 class Unpacker:
@@ -176,7 +176,7 @@ class Unpacker:
                n = self.unpack_uint()
                return self.unpack_fstring(n)
 
-       unpack_opaque = unpack_string
+       unpack_opaque = unpack_fopaque
 
        def unpack_list(self, unpack_item):
                list = []