return NULL;
data_dest = blobmsg_data(attr);
- blob_set_raw_len(buf->head, blob_pad_len(buf->head) - blob_raw_len(attr));
+ blob_set_raw_len(buf->head, blob_pad_len(buf->head) - blob_pad_len(attr));
blob_set_raw_len(attr, blob_raw_len(attr) - maxlen);
return data_dest;
attrlen = blob_raw_len(attr) + len;
blob_set_raw_len(attr, attrlen);
- blob_set_raw_len(buf->head, blob_raw_len(buf->head) + attrlen);
+ blob_set_raw_len(buf->head, blob_raw_len(buf->head) + blob_pad_len(attr));
}
int