SOURCES: python-ssl-nonblocking.patch - updated for 2.4.3

arekm arekm at pld-linux.org
Thu Mar 30 22:32:18 CEST 2006


Author: arekm                        Date: Thu Mar 30 20:32:18 2006 GMT
Module: SOURCES                       Tag: HEAD
---- Log message:
- updated for 2.4.3

---- Files affected:
SOURCES:
   python-ssl-nonblocking.patch (1.3 -> 1.4) 

---- Diffs:

================================================================
Index: SOURCES/python-ssl-nonblocking.patch
diff -u SOURCES/python-ssl-nonblocking.patch:1.3 SOURCES/python-ssl-nonblocking.patch:1.4
--- SOURCES/python-ssl-nonblocking.patch:1.3	Thu Dec 15 18:23:33 2005
+++ SOURCES/python-ssl-nonblocking.patch	Thu Mar 30 22:32:13 2006
@@ -1,5 +1,6 @@
---- Python.org/Lib/test/test_socket_ssl.py.org	2005-12-14 23:04:19.000000000 +0100
-+++ Python/Lib/test/test_socket_ssl.py	2005-12-14 23:06:07.000000000 +0100
+diff -ur Python-2.4.3.org/Lib/test/test_socket_ssl.py Python-2.4.3/Lib/test/test_socket_ssl.py
+--- Python-2.4.3.org/Lib/test/test_socket_ssl.py	2003-07-01 16:49:32.000000000 +0200
++++ Python-2.4.3/Lib/test/test_socket_ssl.py	2006-03-30 22:23:37.724691000 +0200
 @@ -27,6 +27,19 @@
      buf = f.read()
      f.close()
@@ -28,9 +29,10 @@
  
  if __name__ == "__main__":
      test_main()
---- Python.opg/Modules/_ssl.c.org	2005-12-15 18:17:03.000000000 +0100
-+++ Python/Modules/_ssl.c	2005-12-15 18:18:42.000000000 +0100
-@@ -455,6 +455,7 @@
+diff -ur Python-2.4.3.org/Modules/_ssl.c Python-2.4.3/Modules/_ssl.c
+--- Python-2.4.3.org/Modules/_ssl.c	2006-02-13 01:37:09.000000000 +0100
++++ Python-2.4.3/Modules/_ssl.c	2006-03-30 22:25:51.753067250 +0200
+@@ -468,6 +468,7 @@
  	int len = 1024;
  	int sockstate;
  	int err;
@@ -38,7 +40,7 @@
  
  	if (!PyArg_ParseTuple(args, "|i:read", &len))
  		return NULL;
-@@ -462,11 +463,17 @@
+@@ -475,14 +476,20 @@
  	if (!(buf = PyString_FromStringAndSize((char *) 0, len)))
  		return NULL;
  
@@ -47,6 +49,9 @@
 -		PyErr_SetString(PySSLErrorObject, "The read operation timed out");
 -		Py_DECREF(buf);
 -		return NULL;
+-	} else if (sockstate == SOCKET_TOO_LARGE_FOR_SELECT) {
+-		PyErr_SetString(PySSLErrorObject, "Underlying socket too large for select().");
+-		return NULL;
 +	Py_BEGIN_ALLOW_THREADS
 +	pending = SSL_pending(self->ssl);
 +	Py_END_ALLOW_THREADS
@@ -57,8 +62,10 @@
 +			PyErr_SetString(PySSLErrorObject, "The read operation timed out");
 +			Py_DECREF(buf);
 +			return NULL;
++		} else if (sockstate == SOCKET_TOO_LARGE_FOR_SELECT) {
++			PyErr_SetString(PySSLErrorObject, "Underlying socket too large for select().");
++			return NULL;
 +		}
  	}
  	do {
  		err = 0;
-
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/SOURCES/python-ssl-nonblocking.patch?r1=1.3&r2=1.4&f=u



More information about the pld-cvs-commit mailing list