1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2025-01-17 04:52:59 +01:00

sys: fmt: fix converting "0" in fmt_u32_dec()

This commit is contained in:
Kaspar Schleiser 2015-12-07 16:42:39 +01:00
parent 810c623092
commit 8c6f373b98

View File

@ -93,10 +93,9 @@ size_t fmt_u32_dec(char *out, uint32_t val)
if (out) {
char *ptr = out + len;
while(val) {
do {
*--ptr = (val % 10) + '0';
val /= 10;
}
} while ((val /= 10));
}
return len;