]> granicus.if.org Git - python/commitdiff
bpo-36027: Really fix "incompatible pointer type" compiler warning (GH-13761)
authorPetr Viktorin <encukou@gmail.com>
Mon, 3 Jun 2019 00:28:29 +0000 (02:28 +0200)
committerGitHub <noreply@github.com>
Mon, 3 Jun 2019 00:28:29 +0000 (02:28 +0200)
Apologies for the earlier hasty attempt.

Objects/longobject.c

index 858e256ac0b417a7c50812c366a9d766d3bed90c..a1103f697c7379ccd696a09a5082cddaedb374de 100644 (file)
@@ -4243,7 +4243,7 @@ long_invmod(PyLongObject *a, PyLongObject *n)
 
     Py_DECREF(c);
     Py_DECREF(n);
-    if (long_compare(a, (PyObject *)_PyLong_One)) {
+    if (long_compare(a, (PyLongObject *)_PyLong_One)) {
         /* a != 1; we don't have an inverse. */
         Py_DECREF(a);
         Py_DECREF(b);