Gentoo Archives: gentoo-commits

From: "Tiziano Mueller (dev-zero)" <dev-zero@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in dev-python/m2crypto/files: m2crypto-0.18.2-timeval_struct_size.patch
Date: Sun, 24 Feb 2008 11:34:29
Message-Id: E1JTF7i-0002e3-9J@stork.gentoo.org
1 dev-zero 08/02/24 11:34:26
2
3 Added: m2crypto-0.18.2-timeval_struct_size.patch
4 Log:
5 Version bump. Fixes one test-error (upstream bug: http://bugzilla.osafoundation.org/show_bug.cgi?id=11893). Added ~sh keyword wrt bug #172817).
6 (Portage version: 2.1.4.4)
7
8 Revision Changes Path
9 1.1 dev-python/m2crypto/files/m2crypto-0.18.2-timeval_struct_size.patch
10
11 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-python/m2crypto/files/m2crypto-0.18.2-timeval_struct_size.patch?rev=1.1&view=markup
12 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/dev-python/m2crypto/files/m2crypto-0.18.2-timeval_struct_size.patch?rev=1.1&content-type=text/plain
13
14 Index: m2crypto-0.18.2-timeval_struct_size.patch
15 ===================================================================
16 --- M2Crypto/SSL/Connection.py.orig 2008-02-24 12:27:31.000000000 +0100
17 +++ M2Crypto/SSL/Connection.py 2008-02-24 12:28:26.000000000 +0100
18 @@ -4,6 +4,8 @@
19
20 # Python
21 import socket
22 +import struct
23 +sizeof_timeval = struct.calcsize('ll')
24
25 # M2Crypto
26 from Cipher import Cipher, Cipher_Stack
27 @@ -325,10 +327,10 @@
28 return m2.ssl_get_default_session_timeout(self.ssl)
29
30 def get_socket_read_timeout(self):
31 - return timeout.struct_to_timeout(self.socket.getsockopt(socket.SOL_SOCKET, socket.SO_RCVTIMEO, 8))
32 + return timeout.struct_to_timeout(self.socket.getsockopt(socket.SOL_SOCKET, socket.SO_RCVTIMEO, sizeof_timeval))
33
34 def get_socket_write_timeout(self):
35 - return timeout.struct_to_timeout(self.socket.getsockopt(socket.SOL_SOCKET, socket.SO_SNDTIMEO, 8))
36 + return timeout.struct_to_timeout(self.socket.getsockopt(socket.SOL_SOCKET, socket.SO_SNDTIMEO, sizeof_timeval))
37
38 def set_socket_read_timeout(self, timeo):
39 assert isinstance(timeo, timeout.timeout)
40
41
42
43 --
44 gentoo-commits@l.g.o mailing list