This should fix #808.
The approach here is to try and have the Python callback return value be used as the C one is. I'm not totally sure how compatible that is, but IIUC if a Python function doesn't explicitly return it returns None, which should (I guess) fail the PyObject_IsTrue()
check.
I did not test this at all: I didn't even try to build it (thanks to a crappy Internet connection tonight, I didn't wait long enough to fetch the dependencies). This PR should be reviewed as what it is: an attempt at a fix by a guy that doesn't know neither the API nor the plugin :)
However, this should also fix a leak as the return value should likely be DECREF
'd in any case.
https://github.com/geany/geany-plugins/pull/809
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or mute the thread.