/* Check for a proper start() method. */
if (!PyObject_HasAttrString(d->py_dec, "start")) {
/* Check for a proper start() method. */
if (!PyObject_HasAttrString(d->py_dec, "start")) {
/* Check for a proper decode() method. */
if (!PyObject_HasAttrString(d->py_dec, "decode")) {
/* Check for a proper decode() method. */
if (!PyObject_HasAttrString(d->py_dec, "decode")) {
/* If present, options must be a dictionary. */
if (PyObject_HasAttrString(d->py_dec, "options")) {
/* If present, options must be a dictionary. */
if (PyObject_HasAttrString(d->py_dec, "options")) {
if (!PyDict_Check(py_attr)) {
srd_err("Protocol decoder %s options attribute is not "
"a dictionary.", d->name);
if (!PyDict_Check(py_attr)) {
srd_err("Protocol decoder %s options attribute is not "
"a dictionary.", d->name);