[PATCH 1/2] nandwrite: allow hex values in the -s parameter
Baruch Siach
baruch at tkos.co.il
Sun Aug 29 07:36:49 UTC 2010
Signed-off-by: Baruch Siach <baruch at tkos.co.il>
---
miscutils/nandwrite.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/miscutils/nandwrite.c b/miscutils/nandwrite.c
index a20f7f3..d0e4397 100644
--- a/miscutils/nandwrite.c
+++ b/miscutils/nandwrite.c
@@ -71,7 +71,7 @@ int nandwrite_main(int argc UNUSED_PARAM, char **argv)
fd = xopen(argv[0], O_RDWR);
xioctl(fd, MEMGETINFO, &meminfo);
- mtdoffset = xatou(opt_s);
+ mtdoffset = bb_strtou(opt_s, NULL, 0);
/* Pull it into a CPU register (hopefully) - smaller code that way */
meminfo_writesize = meminfo.writesize;
--
1.7.1
More information about the busybox
mailing list