Fix use after free and calls to operator comma in debug mode
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@232703 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -214,10 +214,10 @@ __libcpp_db::__erase_i(void* __i)
|
||||
else
|
||||
q->__next_ = p->__next_;
|
||||
__c_node* c = p->__c_;
|
||||
free(p);
|
||||
--__isz_;
|
||||
if (c != nullptr)
|
||||
c->__remove(p);
|
||||
free(p);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user