mirror of
https://github.com/openwrt/openwrt.git
synced 2024-12-24 07:46:48 +00:00
kernel: mtdsplit_uimage: fix passed info about buf size
We obviously can't use sizeof(*buf) which is always 1. Signed-off-by: Rafał Miłecki <zajec5@gmail.com> SVN-Revision: 44424
This commit is contained in:
parent
02aa882e60
commit
615909819d
@ -113,11 +113,11 @@ static int __mtdsplit_parse_uimage(struct mtd_info *master,
|
||||
|
||||
uimage_size = 0;
|
||||
|
||||
ret = read_uimage_header(master, offset, buf, sizeof(*buf));
|
||||
ret = read_uimage_header(master, offset, buf, MAX_HEADER_LEN);
|
||||
if (ret)
|
||||
continue;
|
||||
|
||||
ret = find_header(buf, sizeof(*buf));
|
||||
ret = find_header(buf, MAX_HEADER_LEN);
|
||||
if (ret < 0) {
|
||||
pr_debug("no valid uImage found in \"%s\" at offset %llx\n",
|
||||
master->name, (unsigned long long) offset);
|
||||
|
Loading…
Reference in New Issue
Block a user