Commit 98f51ff
buffer: fix unintended unsigned overflow
`offset` is user supplied variable and may be bigger than
`ts_obj_length`. There is no need to subtract them and pass along, so
just throw when the subtraction result would overflow.
PR-URL: #7494
Reviewed-By: Ben Noordhuis <info@bnoordhuis.nl>1 parent b3164ae commit 98f51ffCopy full SHA for 98f51ff
File tree
Expand file treeCollapse file tree
1 file changed
+3
-3
lines changedOpen diff view settings
Filter options
- src
Expand file treeCollapse file tree
1 file changed
+3
-3
lines changedOpen diff view settings
Collapse file
+3-3Lines changed: 3 additions & 3 deletions
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| ||
718 | 718 | |
719 | 719 | |
720 | 720 | |
| 721 | + |
| 722 | + |
| 723 | + |
721 | 724 | |
722 | 725 | |
723 | 726 | |
724 | 727 | |
725 | 728 | |
726 | 729 | |
727 | 730 | |
728 | | - |
729 | | - |
730 | | - |
731 | 731 | |
732 | 732 | |
733 | 733 | |
|
0 commit comments