- if (o && o->format->recv) {
- out = o->format->recv(o, sdi, packet);
- if (out && out->len) {
+ if (o && o->format->receive) {
+ if (o->format->receive(o, sdi, packet, &out) == SR_OK && out) {
fwrite(out->str, 1, out->len, outfile);
fflush(outfile);
fwrite(out->str, 1, out->len, outfile);
fflush(outfile);
* is called, so it can properly clean up that module etc. */
if (packet->type == SR_DF_END) {
g_debug("cli: Received SR_DF_END");
* is called, so it can properly clean up that module etc. */
if (packet->type == SR_DF_END) {
g_debug("cli: Received SR_DF_END");