mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 710922 - Don't call m_pools.all() if m_pools isn't initialized. r=luke.
--HG-- extra : rebase_source : 72da22ce0e29d449da9ffa211b4b892ab7796303
This commit is contained in:
parent
cdfcde6a3f
commit
e3cf9cdc72
@ -45,11 +45,14 @@ ExecutableAllocator::sizeOfCode(size_t *method, size_t *regexp, size_t *unused)
|
||||
*method = 0;
|
||||
*regexp = 0;
|
||||
*unused = 0;
|
||||
for (ExecPoolHashSet::Range r = m_pools.all(); !r.empty(); r.popFront()) {
|
||||
ExecutablePool* pool = r.front();
|
||||
*method += pool->m_mjitCodeMethod;
|
||||
*regexp += pool->m_mjitCodeRegexp;
|
||||
*unused += pool->m_allocation.size - pool->m_mjitCodeMethod - pool->m_mjitCodeRegexp;
|
||||
|
||||
if (m_pools.initialized()) {
|
||||
for (ExecPoolHashSet::Range r = m_pools.all(); !r.empty(); r.popFront()) {
|
||||
ExecutablePool* pool = r.front();
|
||||
*method += pool->m_mjitCodeMethod;
|
||||
*regexp += pool->m_mjitCodeRegexp;
|
||||
*unused += pool->m_allocation.size - pool->m_mjitCodeMethod - pool->m_mjitCodeRegexp;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -241,6 +241,7 @@ public:
|
||||
if (destroyCallback)
|
||||
destroyCallback(pool->m_allocation.pages, pool->m_allocation.size);
|
||||
systemRelease(pool->m_allocation);
|
||||
JS_ASSERT(m_pools.initialized());
|
||||
m_pools.remove(m_pools.lookup(pool)); // this asserts if |pool| is not in m_pools
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user