From a4cd266f58d2fc42b99a57896480f51f20b46a87 Mon Sep 17 00:00:00 2001 From: Jason Paryani Date: Wed, 18 Sep 2013 17:19:06 -0700 Subject: [PATCH] Update async a bit --- capnp/async.pyx | 2 +- capnp/asyncHelper.h | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/capnp/async.pyx b/capnp/async.pyx index 5c1b980..afe4605 100644 --- a/capnp/async.pyx +++ b/capnp/async.pyx @@ -14,7 +14,7 @@ from cython.operator cimport dereference as deref cdef extern from "" namespace "std": async.PyPromise movePromise"std::move"(async.PyPromise) -# This is a really weird function. By making it public, we'll be able to call it from asyncHelper.h +# By making it public, we'll be able to call it from asyncHelper.h cdef public object wrap_kj_exception(async.Exception & exception): return None # TODO diff --git a/capnp/asyncHelper.h b/capnp/asyncHelper.h index 62d44c9..f213375 100644 --- a/capnp/asyncHelper.h +++ b/capnp/asyncHelper.h @@ -1,6 +1,6 @@ #include "kj/async.h" #include "Python.h" -#include + extern "C" { PyObject * wrap_kj_exception(kj::Exception &); } @@ -8,7 +8,6 @@ extern "C" { PyObject * wrapPyFunc(PyObject * func, PyObject * arg) { PyObject * result = PyObject_CallFunctionObjArgs(func, arg, NULL); Py_DECREF(func); - Py_DECREF(arg); return result; }