projects
/
project
/
firmware-utils.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
888231d
)
tools: edimax_fw_header: fix suspicious memset usage
author
Florian Fainelli
<florian@openwrt.org>
Sat, 10 Jan 2015 18:08:16 +0000
(18:08 +0000)
committer
Florian Fainelli
<florian@openwrt.org>
Sat, 10 Jan 2015 18:08:16 +0000
(18:08 +0000)
memset() was called with a size argument against a pointer size, not the
structure size itself.
Signed-off-by: Florian Fainelli <florian@openwrt.org>
SVN-Revision: 43913
src/edimax_fw_header.c
patch
|
blob
|
history
diff --git
a/src/edimax_fw_header.c
b/src/edimax_fw_header.c
index ff094da1adeb49fe843207c2ec47176f5873ef0e..b85e3a1781c5e58c40f9bc221d935c67ac6802d0 100644
(file)
--- a/
src/edimax_fw_header.c
+++ b/
src/edimax_fw_header.c
@@
-281,7
+281,7
@@
static int build_fw(void)
/* fill firmware header */
hdr = (struct edimax_header *)buf;
- memset(hdr, 0, sizeof(struct edimax_header
*
));
+ memset(hdr, 0, sizeof(struct edimax_header));
strncpy(hdr->model, model, sizeof(hdr->model));
strncpy(hdr->magic, magic, sizeof(hdr->magic));