summaryrefslogtreecommitdiffstats
path: root/tools/mxsimage.c
diff options
context:
space:
mode:
Diffstat (limited to 'tools/mxsimage.c')
-rw-r--r--tools/mxsimage.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/tools/mxsimage.c b/tools/mxsimage.c
index b214050deb..045b35a39b 100644
--- a/tools/mxsimage.c
+++ b/tools/mxsimage.c
@@ -502,6 +502,7 @@ static int sb_token_to_long(char *tok, uint32_t *rid)
tok += 2;
+ errno = 0;
id = strtoul(tok, &endptr, 16);
if ((errno == ERANGE && id == ULONG_MAX) || (errno != 0 && id == 0)) {
fprintf(stderr, "ERR: Value can't be decoded!\n");
OpenPOWER on IntegriCloud