From ab6acbb76500fe32b66f946b77726f6b76101aeb Mon Sep 17 00:00:00 2001 From: Mark Wooding Date: Sun, 24 Nov 2019 14:50:01 +0000 Subject: [PATCH] key.c: Only set the error code. This briefly makes the error string unavailable, but only because the actual constructor isn't wired up -- and if it were wired up then it would fail immediately because it's programmed to accept only a single argument. --- key.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/key.c b/key.c index dff59ec..997cf3c 100644 --- a/key.c +++ b/key.c @@ -104,7 +104,7 @@ static PyMethodDef keyexc_pymethods[] = { static void keyexc_raise(int err) { - PyObject *arg = Py_BuildValue("(is)", err, key_strerror(err)); + PyObject *arg = Py_BuildValue("(i)", err); if (arg) PyErr_SetObject(keyexc, arg); Py_XDECREF(arg); } -- 2.11.0