diff options
-rw-r--r-- | strings.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -6,7 +6,7 @@ void uint32_to_dec(uint32_t number, char buf[10]) { for (int i = 0; i < 10; i++) { - buf[10 - 1 - i] = number % 10; + buf[10 - 1 - i] = '0' + (number % 10); number /= 10; } } |