Commit 37c5a13
replace alloca with do_alloca in mb_guess_encoding_for_strings
This avoids a crash in cases where the list of candidate encodings is so huge
that alloca would fail. Such crashes have been observed when the list of
encodings was larger than around 208,000 entries.1 parent 84bfe2f commit 37c5a13
3 files changed
+31
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
27 | 27 | | |
28 | 28 | | |
29 | 29 | | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
30 | 34 | | |
31 | 35 | | |
32 | 36 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3376 | 3376 | | |
3377 | 3377 | | |
3378 | 3378 | | |
3379 | | - | |
3380 | | - | |
| 3379 | + | |
| 3380 | + | |
| 3381 | + | |
3381 | 3382 | | |
3382 | 3383 | | |
3383 | 3384 | | |
3384 | 3385 | | |
3385 | 3386 | | |
3386 | 3387 | | |
3387 | 3388 | | |
| 3389 | + | |
3388 | 3390 | | |
3389 | 3391 | | |
3390 | 3392 | | |
| |||
3396 | 3398 | | |
3397 | 3399 | | |
3398 | 3400 | | |
3399 | | - | |
| 3401 | + | |
| 3402 | + | |
| 3403 | + | |
| 3404 | + | |
3400 | 3405 | | |
3401 | 3406 | | |
3402 | 3407 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
0 commit comments