ntoab: Make sure not to get stuck on base 1.
* lib/mes/ntoab.c (ntoab): Make sure not to get stuck on base 1.
This commit is contained in:
parent
1f47a76e7a
commit
b0347bf53d
|
@ -27,7 +27,7 @@ ntoab (long x, int base, int signed_p)
|
||||||
static char itoa_buf[20];
|
static char itoa_buf[20];
|
||||||
char *p = itoa_buf + 11;
|
char *p = itoa_buf + 11;
|
||||||
*p-- = 0;
|
*p-- = 0;
|
||||||
assert(base > 0);
|
assert(base > 1);
|
||||||
|
|
||||||
int sign_p = 0;
|
int sign_p = 0;
|
||||||
unsigned long u;
|
unsigned long u;
|
||||||
|
|
Loading…
Reference in a new issue