summaryrefslogtreecommitdiff
path: root/tools/firmware-utils
diff options
context:
space:
mode:
authorFlorian Fainelli <florian@openwrt.org>2009-07-01 14:58:15 +0000
committerFlorian Fainelli <florian@openwrt.org>2009-07-01 14:58:15 +0000
commit9e9480699070c69ad45dcba5aeb26017a2c08137 (patch)
treeff3a1af8111479dac1a327d69c577841ffceb462 /tools/firmware-utils
parent8a8943671ab5ea01bccf9e8f140a49d71f944137 (diff)
downloadmtk-20170518-9e9480699070c69ad45dcba5aeb26017a2c08137.zip
mtk-20170518-9e9480699070c69ad45dcba5aeb26017a2c08137.tar.gz
mtk-20170518-9e9480699070c69ad45dcba5aeb26017a2c08137.tar.bz2
fix segfault when using the maxlen argument (#4359)
SVN-Revision: 16641
Diffstat (limited to 'tools/firmware-utils')
-rw-r--r--tools/firmware-utils/src/trx.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/tools/firmware-utils/src/trx.c b/tools/firmware-utils/src/trx.c
index 1ad3de5..5e5e77a 100644
--- a/tools/firmware-utils/src/trx.c
+++ b/tools/firmware-utils/src/trx.c
@@ -172,6 +172,7 @@ int main(int argc, char **argv)
fprintf(stderr, "realloc failed");
return EXIT_FAILURE;
}
+ p = (struct trx_header *) buf;
break;
case 'a':
errno = 0;