提交 18ce53ad 编写于 作者: Z zgu

8011968: Kitchensink crashed with SIGSEGV in MemBaseline::baseline

Summary: Simple fix to add NULL pointer check that can cause segv
Reviewed-by: coleenp, ctornqvi
上级 118491a3
......@@ -130,7 +130,7 @@ bool MemBaseline::baseline_malloc_summary(const MemPointerArray* malloc_records)
if (malloc_ptr->is_arena_record()) {
// see if arena memory record present
MemPointerRecord* next_malloc_ptr = (MemPointerRecordEx*)malloc_itr.peek_next();
if (next_malloc_ptr->is_arena_memory_record()) {
if (next_malloc_ptr != NULL && next_malloc_ptr->is_arena_memory_record()) {
assert(next_malloc_ptr->is_memory_record_of_arena(malloc_ptr),
"Arena records do not match");
size = next_malloc_ptr->size();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册