summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--nanddump.c4
-rw-r--r--nandwrite.c2
2 files changed, 3 insertions, 3 deletions
diff --git a/nanddump.c b/nanddump.c
index fe29596..bf95e81 100644
--- a/nanddump.c
+++ b/nanddump.c
@@ -136,7 +136,7 @@ static void process_options(int argc, char * const argv[])
omitbad = true;
break;
case 's':
- start_addr = strtoull(optarg, NULL, 0);
+ start_addr = simple_strtoull(optarg, &error);
break;
case 'f':
if (!(dumpfile = strdup(optarg))) {
@@ -145,7 +145,7 @@ static void process_options(int argc, char * const argv[])
}
break;
case 'l':
- length = strtoull(optarg, NULL, 0);
+ length = simple_strtoull(optarg, &error);
break;
case 'o':
omitoob = true;
diff --git a/nandwrite.c b/nandwrite.c
index bbe69b0..5373a89 100644
--- a/nandwrite.c
+++ b/nandwrite.c
@@ -201,7 +201,7 @@ static void process_options(int argc, char * const argv[])
writeoob = true;
break;
case 's':
- mtdoffset = strtoll(optarg, NULL, 0);
+ mtdoffset = simple_strtoll(optarg, &error);
break;
case 'b':
blockalign = atoi(optarg);