Commit 311f1ce
committed
gh-129275: avoid temporary buffer in dec_as_long()
According to the documentation: "If rdata is non-NULL, it MUST be
allocated by one of libmpdec’s allocation functions and rlen MUST be
correct. If necessary, the function will resize rdata. Resizing is
slow and should not occur if rlen has been obtained by a call to
mpd_sizeinbase."
So, possible resizing in mpd_qexport_u32/16() is for guarding against
broken log10() implementations (log10 is used in the mpd_sizeinbase()).1 parent bb5c687 commit 311f1ce
1 file changed
+17
-19
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3698 | 3698 | | |
3699 | 3699 | | |
3700 | 3700 | | |
3701 | | - | |
3702 | | - | |
3703 | | - | |
3704 | | - | |
3705 | | - | |
3706 | | - | |
3707 | | - | |
| 3701 | + | |
| 3702 | + | |
| 3703 | + | |
| 3704 | + | |
| 3705 | + | |
| 3706 | + | |
| 3707 | + | |
| 3708 | + | |
3708 | 3709 | | |
3709 | 3710 | | |
| 3711 | + | |
| 3712 | + | |
| 3713 | + | |
3710 | 3714 | | |
3711 | | - | |
| 3715 | + | |
| 3716 | + | |
3712 | 3717 | | |
3713 | 3718 | | |
3714 | | - | |
| 3719 | + | |
| 3720 | + | |
3715 | 3721 | | |
3716 | 3722 | | |
3717 | 3723 | | |
3718 | 3724 | | |
| 3725 | + | |
3719 | 3726 | | |
3720 | | - | |
3721 | 3727 | | |
3722 | 3728 | | |
3723 | 3729 | | |
3724 | | - | |
3725 | | - | |
3726 | | - | |
| 3730 | + | |
3727 | 3731 | | |
3728 | | - | |
3729 | | - | |
3730 | | - | |
3731 | | - | |
3732 | | - | |
3733 | | - | |
3734 | 3732 | | |
3735 | 3733 | | |
3736 | 3734 | | |
| |||
0 commit comments