Prevent a NULL deref.

Patch by Rachel Blum <groby@chromium.org>

R=mnaganov@chromium.org

Review URL: http://codereview.chromium.org/7218036

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@8384 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent 0a12f5dc
......@@ -396,8 +396,10 @@ class Logger::NameMap {
void Remove(Address code_address) {
HashMap::Entry* entry = FindEntry(code_address);
if (entry != NULL) DeleteArray(static_cast<const char*>(entry->value));
RemoveEntry(entry);
if (entry != NULL) {
DeleteArray(static_cast<char*>(entry->value));
RemoveEntry(entry);
}
}
void Move(Address from, Address to) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment