]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Issue #23834: Fix socket.sendto(), use the C long type to store the result of
authorVictor Stinner <victor.stinner@gmail.com>
Thu, 2 Apr 2015 15:19:17 +0000 (17:19 +0200)
committerVictor Stinner <victor.stinner@gmail.com>
Thu, 2 Apr 2015 15:19:17 +0000 (17:19 +0200)
sendto() instead of the C int type.

Misc/NEWS
Modules/socketmodule.c

index f9e2863ae7223bd293f3c35cfa1dfacfd5b2cf2b..55f1437e34bf9672750400da2cb52cdde679c9cf 100644 (file)
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -21,6 +21,9 @@ Core and Builtins
 Library
 -------
 
+- Issue #23834: Fix socket.sendto(), use the C long type to store the result of
+  sendto() instead of the C int type.
+
 - Issue #21526: Tkinter now supports new boolean type in Tcl 8.5.
 
 - Issue #23838: linecache now clears the cache and returns an empty result on
index cbc3223d9894e202574b0aa8cf8d7c3ca0b38cc5..5def531c4a3918705a772b8eb613129ef677d0f2 100644 (file)
@@ -2901,7 +2901,8 @@ sock_sendto(PySocketSockObject *s, PyObject *args)
     char *buf;
     Py_ssize_t len;
     sock_addr_t addrbuf;
-    int addrlen, n = -1, flags, timeout;
+    int addrlen, flags, timeout;
+    long n = -1;
     int arglen;
 
     flags = 0;