Commit c8e6a38
committed
extra: handle an edge case in BigUint.to_str().
If any of the digits was one past the maximum (e.g. 10**9 for base 10),
then this wasn't detected correctly and so the length of the digit was
one more than expected, causing a very large allocation.
Fixes #10522.
Fixes #10288.1 parent 90754ae commit c8e6a38
1 file changed
+6
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
660 | 660 | | |
661 | 661 | | |
662 | 662 | | |
663 | | - | |
| 663 | + | |
664 | 664 | | |
665 | 665 | | |
666 | 666 | | |
| |||
2520 | 2520 | | |
2521 | 2521 | | |
2522 | 2522 | | |
| 2523 | + | |
| 2524 | + | |
| 2525 | + | |
| 2526 | + | |
| 2527 | + | |
2523 | 2528 | | |
2524 | 2529 | | |
2525 | 2530 | | |
| |||
0 commit comments