chiark / gitweb /
Merge branch '1.2.x' into 1.3.x
authorMark Wooding <mdw@distorted.org.uk>
Tue, 7 Apr 2020 23:56:01 +0000 (00:56 +0100)
committerMark Wooding <mdw@distorted.org.uk>
Tue, 7 Apr 2020 23:56:01 +0000 (00:56 +0100)
* 1.2.x:
  rand.c: More `Py_ssize_t' fixes.

rand.c

diff --git a/rand.c b/rand.c
index b662fd53cd73ca384ab46e3399338784dbf21823..841a402bf08a2a5b5b5e44f05c89aefd701b59ad 100644 (file)
--- a/rand.c
+++ b/rand.c
@@ -938,7 +938,7 @@ static PyTypeObject gclatinrand_pytype_skel = {
 static PyObject *sslprf_pynew(PyTypeObject *ty, PyObject *arg, PyObject *kw)
 {
   char *k, *s;
-  int ksz, ssz;
+  Py_ssize_t ksz, ssz;
   const gchash *hco = &md5, *hci = &sha;
   PyObject *rc = 0;
   static const char *const kwlist[] = { "key", "seed", "ohash", "ihash", 0 };
@@ -955,7 +955,7 @@ end:
 static PyObject *tlsdx_pynew(PyTypeObject *ty, PyObject *arg, PyObject *kw)
 {
   char *k, *s;
-  int ksz, ssz;
+  Py_ssize_t ksz, ssz;
   const gcmac *mc = &sha_hmac;
   PyObject *rc = 0;
   static const char *const kwlist[] = { "key", "seed", "mac", 0 };
@@ -972,7 +972,7 @@ end:
 static PyObject *tlsprf_pynew(PyTypeObject *ty, PyObject *arg, PyObject *kw)
 {
   char *k, *s;
-  int ksz, ssz;
+  Py_ssize_t ksz, ssz;
   const gcmac *mcl = &md5_hmac, *mcr = &sha_hmac;
   PyObject *rc = 0;
   static const char *const kwlist[] = { "key", "seed", "lmac", "rmac", 0 };
@@ -1138,7 +1138,7 @@ static PyTypeObject tlsprf_pytype_skel = {
 static PyObject *dsarand_pynew(PyTypeObject *ty, PyObject *arg, PyObject *kw)
 {
   char *p;
-  int sz;
+  Py_ssize_t sz;
   PyObject *rc = 0;
   static const char *const kwlist[] = { "seed", 0 };