Commit 733cb1e
deps: cherry-pick b87d408 from upstream V8
Original commit message:
[heap-profiler] Fix a use-after-free when snapshots are deleted
If a caller starts the sampling heap profiler and takes a snapshot,
and then deletes the snapshot before the sampling has completed, a
use-after-free will occur on the StringsStorage pointer.
The same issue applies for StartTrackingHeapObjects which shares the
same StringsStorage object.
Bug: v8:8373
Change-Id: I5d69d60d3f9465f9dd3b3bef107c204e0fda0643
Reviewed-on: https://chromium-review.googlesource.com/c/1301477
Commit-Queue: Peter Marshall <petermarshall@chromium.org>
Reviewed-by: Alexei Filippov <alph@chromium.org>
Cr-Commit-Position: refs/heads/master@{#57114}
PR-URL: #24272
Refs:
v8/v8@b87d408
Reviewed-By: Colin Ihrig <cjihrig@gmail.com>
Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>1 parent 51643c2 commit 733cb1eCopy full SHA for 733cb1e
File tree
Expand file treeCollapse file tree
4 files changed
+53
-2
lines changedOpen diff view settings
Filter options
- deps/v8
- src/profiler
- test/cctest
Expand file treeCollapse file tree
4 files changed
+53
-2
lines changedOpen diff view settings
Collapse file
+1-1Lines changed: 1 addition & 1 deletion
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| ||
33 | 33 | |
34 | 34 | |
35 | 35 | |
36 | | - |
| 36 | + |
37 | 37 | |
38 | 38 | |
39 | 39 | |
|
Collapse file
deps/v8/src/profiler/heap-profiler.cc
Copy file name to clipboardExpand all lines: deps/v8/src/profiler/heap-profiler.cc+8-1Lines changed: 8 additions & 1 deletion
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| ||
23 | 23 | |
24 | 24 | |
25 | 25 | |
26 | | - |
| 26 | + |
27 | 27 | |
28 | 28 | |
| 29 | + |
| 30 | + |
| 31 | + |
| 32 | + |
| 33 | + |
29 | 34 | |
30 | 35 | |
31 | 36 | |
| ||
126 | 131 | |
127 | 132 | |
128 | 133 | |
| 134 | + |
129 | 135 | |
130 | 136 | |
131 | 137 | |
| ||
159 | 165 | |
160 | 166 | |
161 | 167 | |
| 168 | + |
162 | 169 | |
163 | 170 | |
164 | 171 | |
|
Collapse file
deps/v8/src/profiler/heap-profiler.h
Copy file name to clipboardExpand all lines: deps/v8/src/profiler/heap-profiler.h+2Lines changed: 2 additions & 0 deletions
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| ||
92 | 92 | |
93 | 93 | |
94 | 94 | |
| 95 | + |
| 96 | + |
95 | 97 | |
96 | 98 | |
97 | 99 | |
|
Collapse file
deps/v8/test/cctest/test-heap-profiler.cc
Copy file name to clipboardExpand all lines: deps/v8/test/cctest/test-heap-profiler.cc+42Lines changed: 42 additions & 0 deletions
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| ||
3690 | 3690 | |
3691 | 3691 | |
3692 | 3692 | |
| 3693 | + |
| 3694 | + |
| 3695 | + |
| 3696 | + |
| 3697 | + |
| 3698 | + |
| 3699 | + |
| 3700 | + |
| 3701 | + |
| 3702 | + |
| 3703 | + |
| 3704 | + |
| 3705 | + |
| 3706 | + |
| 3707 | + |
| 3708 | + |
| 3709 | + |
| 3710 | + |
| 3711 | + |
| 3712 | + |
| 3713 | + |
| 3714 | + |
| 3715 | + |
| 3716 | + |
| 3717 | + |
| 3718 | + |
| 3719 | + |
| 3720 | + |
| 3721 | + |
| 3722 | + |
| 3723 | + |
| 3724 | + |
| 3725 | + |
| 3726 | + |
| 3727 | + |
| 3728 | + |
| 3729 | + |
| 3730 | + |
| 3731 | + |
| 3732 | + |
| 3733 | + |
| 3734 | + |
0 commit comments