projects
/
project
/
ubus.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
fix max message length handling - exclude the header
[project/ubus.git]
/
ubusd.c
diff --git
a/ubusd.c
b/ubusd.c
index
aa74550
..
14eb537
100644
(file)
--- a/
ubusd.c
+++ b/
ubusd.c
@@
-206,7
+206,7
@@
retry:
if (cl->pending_msg_offset < sizeof(cl->hdrbuf))
goto out;
if (cl->pending_msg_offset < sizeof(cl->hdrbuf))
goto out;
- if (blob_
len(&cl->hdrbuf.data) + sizeof(cl->hdrbuf
) > UBUS_MAX_MSGLEN)
+ if (blob_
pad_len(&cl->hdrbuf.data
) > UBUS_MAX_MSGLEN)
goto disconnect;
cl->pending_msg = ubus_msg_new(NULL, blob_raw_len(&cl->hdrbuf.data), false);
goto disconnect;
cl->pending_msg = ubus_msg_new(NULL, blob_raw_len(&cl->hdrbuf.data), false);