diff options
author | Rafał Miłecki <zajec5@gmail.com> | 2015-07-07 21:21:49 +0000 |
---|---|---|
committer | Rafał Miłecki <zajec5@gmail.com> | 2015-07-07 21:21:49 +0000 |
commit | d88e5cfd6c268519a69d4220194c7d19b43486d2 (patch) | |
tree | 3cff6c66a3f0b212240a1b44b507896100ebd38a /tools/firmware-utils/src/lzma2eva.c | |
parent | 599081f3e41f2b3551a39e0f06edfe0d4d3fa836 (diff) | |
download | master-187ad058-d88e5cfd6c268519a69d4220194c7d19b43486d2.tar.gz master-187ad058-d88e5cfd6c268519a69d4220194c7d19b43486d2.tar.bz2 master-187ad058-d88e5cfd6c268519a69d4220194c7d19b43486d2.zip |
nvram: fix "Segmentation fault" caused by setting memory out of buffer
Some MTD partitions with NVRAM have content starting in the middle. In
such case offset is set and nvram_header returns pointer to the middle.
It means we have to respect offset when calculating remaining space.
By the way use real MTD partition size (nvram_part_size variable) as we
may want to bump NVRAM_SPACE in the (very near) future.
Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@46251 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'tools/firmware-utils/src/lzma2eva.c')
0 files changed, 0 insertions, 0 deletions