Browse Source

libubus: fix synchronous ubus_notify without waiting for a timeout

Signed-off-by: Felix Fietkau <nbd@openwrt.org>
master
Felix Fietkau 8 years ago
parent
commit
460301e62d
1 changed files with 3 additions and 1 deletions
  1. +3
    -1
      libubus-req.c

+ 3
- 1
libubus-req.c View File

@ -285,8 +285,10 @@ int ubus_notify(struct ubus_context *ctx, struct ubus_object *obj,
if (ret < 0)
return ret;
if (timeout < 0)
if (timeout < 0) {
ubus_abort_request(ctx, &req.req);
return 0;
}
return ubus_complete_request(ctx, &req.req, timeout);
}


Loading…
Cancel
Save