aboutsummaryrefslogtreecommitdiffstats
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
commit7d7ed4e8a3a10adaa46ae2c3f2c1fd39e3960753 (patch)
treec511a2572248403fa212688c07d28b9ae46c6014 /tools/firmware-utils
parent7bba3b72d734facab7ff2ed77bfe33c6056adce6 (diff)
downloadupstream-7d7ed4e8a3a10adaa46ae2c3f2c1fd39e3960753.tar.gz
upstream-7d7ed4e8a3a10adaa46ae2c3f2c1fd39e3960753.tar.bz2
upstream-7d7ed4e8a3a10adaa46ae2c3f2c1fd39e3960753.zip
[tools] fix segfault when using the maxlen argument (#4359)
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@16641 3c298f89-4303-0410-b956-a3cf2f4a3e73
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 1ad3de54f6..5e5e77a492 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;