diff options
author | Ralf Baechle <ralf@linux-mips.org> | 1997-03-25 23:40:36 +0000 |
---|---|---|
committer | <ralf@linux-mips.org> | 1997-03-25 23:40:36 +0000 |
commit | 7206675c40394c78a90e74812bbdbf8cf3cca1be (patch) | |
tree | 251895cf5a0008e2b4ce438cb01ad4d55fb5b97b /lib | |
parent | beb116954b9b7f3bb56412b2494b562f02b864b1 (diff) |
Import of Linux/MIPS 2.1.14.2
Diffstat (limited to 'lib')
-rw-r--r-- | lib/.cvsignore | 1 | ||||
-rw-r--r-- | lib/vsprintf.c | 25 |
2 files changed, 1 insertions, 25 deletions
diff --git a/lib/.cvsignore b/lib/.cvsignore new file mode 100644 index 000000000..4671378ae --- /dev/null +++ b/lib/.cvsignore @@ -0,0 +1 @@ +.depend diff --git a/lib/vsprintf.c b/lib/vsprintf.c index f1adf6fc2..8f813c655 100644 --- a/lib/vsprintf.c +++ b/lib/vsprintf.c @@ -59,27 +59,14 @@ static int skip_atoi(const char **s) #define SPECIAL 32 /* 0x */ #define LARGE 64 /* use 'ABCDEF' instead of 'abcdef' */ -#ifdef __mips64 -#define do_div(n,base) ({ \ -long long __res; \ -__res = ((unsigned long long) n) % (unsigned long long) base; \ -n = ((unsigned long long) n) / (unsigned long long) base; \ -__res; }) -#else #define do_div(n,base) ({ \ int __res; \ __res = ((unsigned long) n) % (unsigned) base; \ n = ((unsigned long) n) / (unsigned) base; \ __res; }) -#endif -#ifdef __mips64 -static char * number(char * str, long long num, int base, int size, int precision - ,int type) -#else static char * number(char * str, long num, int base, int size, int precision ,int type) -#endif { char c,sign,tmp[66]; const char *digits="0123456789abcdefghijklmnopqrstuvwxyz"; @@ -147,11 +134,7 @@ static char * number(char * str, long num, int base, int size, int precision int vsprintf(char *buf, const char *fmt, va_list args) { int len; -#ifdef __mips64 - unsigned long long num; -#else unsigned long num; -#endif int i, base; char * str; const char *s; @@ -261,9 +244,6 @@ int vsprintf(char *buf, const char *fmt, va_list args) if (qualifier == 'l') { long * ip = va_arg(args, long *); *ip = (str - buf); - } else if (qualifier == 'L') { - long long * ip = va_arg(args, long long *); - *ip = (str - buf); } else { int * ip = va_arg(args, int *); *ip = (str - buf); @@ -303,11 +283,6 @@ int vsprintf(char *buf, const char *fmt, va_list args) num = va_arg(args, short); else num = va_arg(args, unsigned short); - else if (qualifier == 'L') - if (flags & SIGN) - num = va_arg(args, long long); - else - num = va_arg(args, unsigned long long); else if (flags & SIGN) num = va_arg(args, int); else |