chiark / gitweb /
buffer.c: Funnel control through a common exit point.
authorMark Wooding <mdw@distorted.org.uk>
Tue, 22 Oct 2019 10:29:09 +0000 (11:29 +0100)
committerMark Wooding <mdw@distorted.org.uk>
Sat, 11 Apr 2020 11:44:21 +0000 (12:44 +0100)
I'm not going on a rampage to fix this throughout the code (yet?), but
while I'm here I might as well.

buffer.c

index f615858594faa74f004df7f7445ecef33ccbcbb3..7a3bec7f57e54da8a049663a439eefbf0f76d318 100644 (file)
--- a/buffer.c
+++ b/buffer.c
@@ -186,12 +186,13 @@ static PyObject *rbmeth_getecptraw(PyObject *me, PyObject *arg)
 {
   PyObject *cobj;
   ec pt = EC_INIT;
+  PyObject *rc = 0;
   if (!PyArg_ParseTuple(arg, "O!:getecptraw", eccurve_pytype, &cobj))
     goto end;
   if (ec_getraw(ECCURVE_C(cobj), BUF_B(me), &pt)) BUFERR("buffer exhausted");
-  return (ecpt_pywrapout(cobj, &pt));
+  rc = ecpt_pywrapout(cobj, &pt);
 end:
-  return (0);
+  return (rc);
 }
 
 static PyObject *rbmeth_getge(PyObject *me, PyObject *arg)