diff options
Diffstat (limited to 'type_decoder.c')
-rw-r--r-- | type_decoder.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/type_decoder.c b/type_decoder.c index 16e25a7..a01d785 100644 --- a/type_decoder.c +++ b/type_decoder.c @@ -518,14 +518,13 @@ static PyObject *get_current_pinvalues(const struct srd_decoder_inst *di) PyObject *py_pinvalues; PyGILState_STATE gstate; - gstate = PyGILState_Ensure(); - if (!di) { srd_err("Invalid decoder instance."); - PyGILState_Release(gstate); return NULL; } + gstate = PyGILState_Ensure(); + py_pinvalues = PyTuple_New(di->dec_num_channels); for (i = 0; i < di->dec_num_channels; i++) { |