projects
/
oweals
/
ubus.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
04e644b
)
libubus: add socket EOF handling to ubus_complete_request()
author
Felix Fietkau
<nbd@openwrt.org>
Wed, 9 Dec 2015 17:35:07 +0000
(18:35 +0100)
committer
Felix Fietkau
<nbd@openwrt.org>
Wed, 9 Dec 2015 17:35:07 +0000
(18:35 +0100)
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
libubus-req.c
patch
|
blob
|
history
diff --git
a/libubus-req.c
b/libubus-req.c
index bf19f3670ea5b215190dfcce125c358f616c72a4..416adaba2f9fca50225d9915b2512026a7b481f1 100644
(file)
--- a/
libubus-req.c
+++ b/
libubus-req.c
@@
-160,6
+160,10
@@
int ubus_complete_request(struct ubus_context *ctx, struct ubus_request *req,
ubus_poll_data(ctx, (unsigned int) timeout);
uloop_cancelled = cancelled;
+ if (ctx->sock.eof) {
+ ubus_set_req_status(req, UBUS_STATUS_CONNECTION_FAILED);
+ break;
+ }
}
ctx->stack_depth--;
if (ctx->stack_depth)