blobmsg: reuse blobmsg_namelen in blobmsg_data
[project/libubox.git] / blobmsg.c
index 7cd0934600deac2f92c98a59cbc51cfa434a25a0..48dba8156d58ffe60af2604e59250b8a8e3cf4c9 100644 (file)
--- a/blobmsg.c
+++ b/blobmsg.c
@@ -25,12 +25,6 @@ static const int blob_type[__BLOBMSG_TYPE_LAST] = {
        [BLOBMSG_TYPE_UNSPEC] = BLOB_ATTR_BINARY,
 };
 
-static uint16_t
-blobmsg_namelen(const struct blobmsg_hdr *hdr)
-{
-       return be16_to_cpu(hdr->namelen);
-}
-
 bool blobmsg_check_attr(const struct blob_attr *attr, bool name)
 {
        return blobmsg_check_attr_len(attr, name, blob_raw_len(attr));