make message data on invoke() optional

This commit is contained in:
Felix Fietkau 2011-01-31 17:26:29 +01:00
parent 1555e4610f
commit 57615abd9b

View file

@ -444,6 +444,7 @@ 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);
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);