From 05bf627d01d425a3ec8726fdf3b14383a5234f08 Mon Sep 17 00:00:00 2001 From: leitner Date: Mon, 25 Apr 2005 19:41:51 +0000 Subject: [PATCH] fix scan_xlong, scan_xlonglong and scan_8long --- CHANGES | 1 + scan/scan_8long.c | 2 +- scan/scan_xlong.c | 2 +- scan/scan_xlonglong.c | 2 +- 4 files changed, 4 insertions(+), 3 deletions(-) diff --git a/CHANGES b/CHANGES index 62099e6..fbdeb04 100644 --- a/CHANGES +++ b/CHANGES @@ -3,6 +3,7 @@ fix a few man pages optimize fmt_base64 (Dan Gundlach) gcc 4 cleanups (mostly unsigned char* vs char*) + fix scan_xlong, scan_xlonglong and scan_8long 0.22: uh, the scope_id detection #defined the wrong constant. libowfat diff --git a/scan/scan_8long.c b/scan/scan_8long.c index a675804..1acb8f9 100644 --- a/scan/scan_8long.c +++ b/scan/scan_8long.c @@ -2,7 +2,7 @@ unsigned int scan_8long(const char *src,unsigned long *dest) { register const char *tmp=src; - register int l=0; + register unsigned long l=0; register unsigned char c; while ((c=*tmp-'0')<8) { l=l*8+c; diff --git a/scan/scan_xlong.c b/scan/scan_xlong.c index 71e0787..c885790 100644 --- a/scan/scan_xlong.c +++ b/scan/scan_xlong.c @@ -2,7 +2,7 @@ unsigned int scan_xlong(const char *src,unsigned long *dest) { register const char *tmp=src; - register int l=0; + register unsigned long l=0; register unsigned char c; while ((c=scan_fromhex(*tmp))<16) { l=(l<<4)+c; diff --git a/scan/scan_xlonglong.c b/scan/scan_xlonglong.c index 78ee7d9..0c547a8 100644 --- a/scan/scan_xlonglong.c +++ b/scan/scan_xlonglong.c @@ -2,7 +2,7 @@ unsigned int scan_xlonglong(const char* src,unsigned long long* dest) { register const char *tmp=src; - register int l=0; + register long long l=0; register unsigned char c; while ((c=scan_fromhex(*tmp))<16) { l=(l<<4)+c;