projects
/
project
/
ubus.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1555e46
)
make message data on invoke() optional
author
Felix Fietkau
<nbd@openwrt.org>
Mon, 31 Jan 2011 16:26:29 +0000
(17:26 +0100)
committer
Felix Fietkau
<nbd@openwrt.org>
Mon, 31 Jan 2011 16:26:29 +0000
(17:26 +0100)
libubus.c
patch
|
blob
|
history
diff --git
a/libubus.c
b/libubus.c
index 1342ba19463810d09220c29017ca452db60c3e82..fa7f5ca0df9447f993b8c1820057a3b2b316bc2c 100644
(file)
--- a/
libubus.c
+++ b/
libubus.c
@@
-444,7
+444,8
@@
void ubus_invoke_async(struct ubus_context *ctx, uint32_t obj, const char *metho
blob_buf_init(&b, 0);
blob_put_int32(&b, UBUS_ATTR_OBJID, obj);
blob_put_string(&b, UBUS_ATTR_METHOD, method);
- blob_put(&b, UBUS_ATTR_DATA, blob_data(msg), blob_len(msg));
+ if (msg)
+ blob_put(&b, UBUS_ATTR_DATA, blob_data(msg), blob_len(msg));
ubus_start_request(ctx, req, b.head, UBUS_MSG_INVOKE, obj);
}