diff options
author | Felix Fietkau <nbd@openwrt.org> | 2011-10-06 19:57:13 +0400 |
---|---|---|
committer | Felix Fietkau <nbd@openwrt.org> | 2011-10-06 19:57:13 +0400 |
commit | 51711be6251be4ae5e53f9369ae04598b06df0e7 (patch) | |
tree | b7df042f992304d1582366210fade3754018ef69 /blob.c | |
parent | 7c80b7c5147ac55455464224bd0a3f6aac0b51d0 (diff) |
fix more instances of uninitialized padding bytes
Diffstat (limited to 'blob.c')
-rw-r--r-- | blob.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -67,6 +67,7 @@ blob_add(struct blob_buf *buf, struct blob_attr *pos, int id, int payload) } blob_init(attr, id, payload + sizeof(struct blob_attr)); + blob_fill_pad(attr); return attr; } @@ -91,7 +92,7 @@ blob_buf_free(struct blob_buf *buf) buf->buflen = 0; } -static void +void blob_fill_pad(struct blob_attr *attr) { char *buf = (char *) attr; @@ -109,7 +110,6 @@ blob_set_raw_len(struct blob_attr *attr, unsigned int len) len &= BLOB_ATTR_LEN_MASK; len |= (id << BLOB_ATTR_ID_SHIFT) & BLOB_ATTR_ID_MASK; attr->id_len = cpu_to_be32(len); - blob_fill_pad(attr); } struct blob_attr * |