We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent af53772 commit 7e1d891Copy full SHA for 7e1d891
cores/esp8266/Print.cpp
@@ -280,8 +280,9 @@ size_t Print::printNumber(unsigned long n, uint8_t base) {
280
base = 10;
281
282
do {
283
- char c = n % base;
+ unsigned long m = n;
284
n /= base;
285
+ char c = m - base * n;
286
287
*--str = c < 10 ? c + '0' : c + 'A' - 10;
288
} while(n);
@@ -300,8 +301,9 @@ size_t Print::printNumber(unsigned long long n, uint8_t base) {
300
301
302
303
304
305
306
307
308
309
0 commit comments