X-Git-Url: https://sigrok.org/gitweb/?p=libsigrokdecode.git;a=blobdiff_plain;f=controller.c;h=ebda088932ea4885f5b834c81e0b914773ee137e;hp=f5e272edea49b8c1d5b17bee1502456ec7f9e61a;hb=21481b6609641fb3076290dad915a3a6259ce05a;hpb=639c56898e88aae99a7b91a5c6d2b7870956d648 diff --git a/controller.c b/controller.c index f5e272e..ebda088 100644 --- a/controller.c +++ b/controller.c @@ -204,6 +204,10 @@ int srd_instance_set_options(struct srd_decoder_instance *di, goto err_out; if (!(py_classval = PyList_GetItem(py_optlist, 1))) goto err_out; + if (!PyUnicode_Check(py_classval) && !PyLong_Check(py_classval)) { + srd_err("Options of type %s are not yet supported.", Py_TYPE(py_classval)->tp_name); + goto err_out; + } if ((value = g_hash_table_lookup(options, key))) { /* An override for this option was provided. */