[Python-checkins] python/dist/src/Modules _ssl.c,1.14,1.15

loewis at users.sourceforge.net loewis at users.sourceforge.net
Mon Oct 27 09:24:39 EST 2003


Update of /cvsroot/python/python/dist/src/Modules
In directory sc8-pr-cvs1:/tmp/cvs-serv1757/Modules

Modified Files:
	_ssl.c 
Log Message:
Patch #803998: Correctly check for error in SSL_write.


Index: _ssl.c
===================================================================
RCS file: /cvsroot/python/python/dist/src/Modules/_ssl.c,v
retrieving revision 1.14
retrieving revision 1.15
diff -C2 -d -r1.14 -r1.15
*** _ssl.c	20 Oct 2003 14:01:52 -0000	1.14
--- _ssl.c	27 Oct 2003 14:24:37 -0000	1.15
***************
*** 374,381 ****
  	char *data;
  	int len;
  	int timedout;
  	int err;
  
! 	if (!PyArg_ParseTuple(args, "s#:write", &data, &len))
  		return NULL;
  
--- 374,382 ----
  	char *data;
  	int len;
+ 	int count;
  	int timedout;
  	int err;
  
! 	if (!PyArg_ParseTuple(args, "s#:write", &data, &count))
  		return NULL;
  
***************
*** 388,392 ****
  		err = 0;
  		Py_BEGIN_ALLOW_THREADS
! 		len = SSL_write(self->ssl, data, len);
  		err = SSL_get_error(self->ssl, len);
  		Py_END_ALLOW_THREADS
--- 389,393 ----
  		err = 0;
  		Py_BEGIN_ALLOW_THREADS
! 		len = SSL_write(self->ssl, data, count);
  		err = SSL_get_error(self->ssl, len);
  		Py_END_ALLOW_THREADS





More information about the Python-checkins mailing list