Skip to content
Snippets Groups Projects
Commit 4a77cef7 authored by alexey.stratulat's avatar alexey.stratulat
Browse files

[*] Redesigned custom datum creation function and wrapper for it, now the...

[*] Redesigned custom datum creation function and wrapper for it, now the function returns a string or NULL. And python-cellframe returns either a string or None.
parent 41e2c66e
No related branches found
No related tags found
No related merge requests found
......@@ -29,6 +29,8 @@ PyObject *wrapping_dap_chain_net_srv_datum_create(PyObject *self, PyObject *args
}
void *l_data = PyBytes_AsString(obj_data_in_datum);
size_t l_data_size = PyBytes_Size(obj_data_in_datum);
int res = dap_chain_net_srv_datum_custom_add(((PyDapChainObject*)obj_chain)->chain_t, l_data, l_data_size);
return Py_BuildValue("i", res);
char* res = dap_chain_net_srv_datum_custom_add(((PyDapChainObject*)obj_chain)->chain_t, l_data, l_data_size);
if (res == NULL)
return Py_None;
return Py_BuildValue("s", res);
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment