struct livebox *handler;
char *new_content;
int ret;
+ int status;
int pinup;
- ret = packet_get(packet, "iisss", &ret, &pinup, &pkgname, &id, &content);
+ ret = packet_get(packet, "iisss", &status, &pinup, &pkgname, &id, &content);
if (ret != 5) {
ErrPrint("Invalid argument\n");
goto out;
goto out;
}
- if (ret == 0) {
+ if (status == 0) {
new_content = strdup(content);
if (new_content) {
free(handler->content);
handler->is_pinned_up = pinup;
} else {
ErrPrint("Heap: %s\n", strerror(errno));
- ret = LB_STATUS_ERROR_MEMORY;
+ status = LB_STATUS_ERROR_MEMORY;
}
}
handler->pinup_cb = NULL;
handler->pinup_cbdata = NULL;
- cb(handler, ret, cbdata);
- } else if (ret == 0) {
+ cb(handler, status, cbdata);
+ } else if (status == 0) {
lb_invoke_event_handler(handler, LB_EVENT_PINUP_CHANGED);
}