aboutsummaryrefslogtreecommitdiffstats
path: root/tools/firmware-utils/src/mkrasimage.c
Commit message (Collapse)AuthorAgeFilesLines
* mkrasimage: fix segmentation faultMichael T Farnworth2020-03-011-9/+10
| | | | | | | | | | | | | Code was attempting to determine the size of the file before it was actually known and allocating insufficient memory space. Images above a certain size caused a segmentation fault. Moving the calloc() ensured ensured that large images didn't result in a buffer overflow on memcpy(). Signed-off-by: Michael T Farnworth <michael@turf.org> [fixed name in From to match one in SoB] Signed-off-by: Petr Štetiar <ynezz@true.cz>
* tools/mkrasimage: Add support for 128k header sizeAndré Valentin2019-10-271-3/+8
| | | | | | 128k header size support is needed for ZyXEL NBG6716. Signed-off-by: André Valentin <avalentin@marcant.net>
* build: add mkrasimageDavid Bauer2018-08-281-0/+459
The current make-ras.sh image generation script for the ZyXEL NBG6617 has portability issues with bash. Because of this, factory images are currently not built correctly by the OpenWRT buildbots. This commit replaces the make-ras.sh by C-written mkrasimage. The new mkrasimage is also compatible with other ZyXEL devices using the ras image-format. This is not tested with the NBG6616 but it correctly builds the header for ZyXEL factory image. Signed-off-by: David Bauer <mail@david-bauer.net>