aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/lj_strfmt_num.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/lj_strfmt_num.c b/src/lj_strfmt_num.c
index 79ec0263..c6e776aa 100644
--- a/src/lj_strfmt_num.c
+++ b/src/lj_strfmt_num.c
@@ -454,7 +454,8 @@ static char *lj_strfmt_wfnum(SBuf *sb, SFormat sf, lua_Number n, char *p)
454 prec--; 454 prec--;
455 if (!i) { 455 if (!i) {
456 if (ndlo == ndhi) { prec = 0; break; } 456 if (ndlo == ndhi) { prec = 0; break; }
457 lj_strfmt_wuint9(tail, nd[++ndlo]); 457 ndlo = (ndlo + 1) & 0x3f;
458 lj_strfmt_wuint9(tail, nd[ndlo]);
458 i = 9; 459 i = 9;
459 } 460 }
460 } 461 }