Commit 392cff4
committed
Fix panic if too many elements specified in
If a buffer was created with a given size, but a greater number of elements
were then specified, we attempted to copy them all, causing a panic. This
would only be done by broken/malicious AML. Fix this by capping the copied
elements at the specified buffer size.DefBuffer
1 parent ba676e1 commit 392cff4
1 file changed
Lines changed: 10 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
663 | 663 | | |
664 | 664 | | |
665 | 665 | | |
666 | | - | |
| 666 | + | |
| 667 | + | |
667 | 668 | | |
668 | 669 | | |
669 | | - | |
670 | | - | |
| 670 | + | |
| 671 | + | |
| 672 | + | |
| 673 | + | |
| 674 | + | |
| 675 | + | |
| 676 | + | |
| 677 | + | |
671 | 678 | | |
672 | 679 | | |
673 | 680 | | |
| |||
0 commit comments