<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[242415] releases/WebKitGTK/webkit-2.24/Source/bmalloc</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://trac.webkit.org/projects/webkit/changeset/242415">242415</a></dd>
<dt>Author</dt> <dd>carlosgc@webkit.org</dd>
<dt>Date</dt> <dd>2019-03-05 00:43:03 -0800 (Tue, 05 Mar 2019)</dd>
</dl>

<h3>Log Message</h3>
<pre>Merge <a href="http://trac.webkit.org/projects/webkit/changeset/241818">r241818</a> - Unreviewed, rolling out <a href="http://trac.webkit.org/projects/webkit/changeset/241789">r241789</a>.
https://bugs.webkit.org/show_bug.cgi?id=194856

GuardMalloc crashes (Requested by yusukesuzuki on #webkit).

Reverted changeset:

"[bmalloc] bmalloc::Cache should not be instantiated if we are
using system malloc"
https://bugs.webkit.org/show_bug.cgi?id=194811
https://trac.webkit.org/changeset/241789</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#releasesWebKitGTKwebkit224SourcebmallocChangeLog">releases/WebKitGTK/webkit-2.24/Source/bmalloc/ChangeLog</a></li>
<li><a href="#releasesWebKitGTKwebkit224SourcebmallocbmallocAllocatorcpp">releases/WebKitGTK/webkit-2.24/Source/bmalloc/bmalloc/Allocator.cpp</a></li>
<li><a href="#releasesWebKitGTKwebkit224SourcebmallocbmallocAllocatorh">releases/WebKitGTK/webkit-2.24/Source/bmalloc/bmalloc/Allocator.h</a></li>
<li><a href="#releasesWebKitGTKwebkit224SourcebmallocbmallocCachecpp">releases/WebKitGTK/webkit-2.24/Source/bmalloc/bmalloc/Cache.cpp</a></li>
<li><a href="#releasesWebKitGTKwebkit224SourcebmallocbmallocCacheh">releases/WebKitGTK/webkit-2.24/Source/bmalloc/bmalloc/Cache.h</a></li>
<li><a href="#releasesWebKitGTKwebkit224SourcebmallocbmallocDeallocatorcpp">releases/WebKitGTK/webkit-2.24/Source/bmalloc/bmalloc/Deallocator.cpp</a></li>
<li><a href="#releasesWebKitGTKwebkit224SourcebmallocbmallocDeallocatorh">releases/WebKitGTK/webkit-2.24/Source/bmalloc/bmalloc/Deallocator.h</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="releasesWebKitGTKwebkit224SourcebmallocChangeLog"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.24/Source/bmalloc/ChangeLog (242414 => 242415)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.24/Source/bmalloc/ChangeLog  2019-03-05 08:42:59 UTC (rev 242414)
+++ releases/WebKitGTK/webkit-2.24/Source/bmalloc/ChangeLog     2019-03-05 08:43:03 UTC (rev 242415)
</span><span class="lines">@@ -1,3 +1,17 @@
</span><ins>+2019-02-20  Commit Queue  <commit-queue@webkit.org>
+
+        Unreviewed, rolling out r241789.
+        https://bugs.webkit.org/show_bug.cgi?id=194856
+
+        GuardMalloc crashes (Requested by yusukesuzuki on #webkit).
+
+        Reverted changeset:
+
+        "[bmalloc] bmalloc::Cache should not be instantiated if we are
+        using system malloc"
+        https://bugs.webkit.org/show_bug.cgi?id=194811
+        https://trac.webkit.org/changeset/241789
+
</ins><span class="cx"> 2019-02-19  Yusuke Suzuki  <ysuzuki@apple.com>
</span><span class="cx"> 
</span><span class="cx">         [bmalloc] bmalloc::Cache should not be instantiated if we are using system malloc
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit224SourcebmallocbmallocAllocatorcpp"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.24/Source/bmalloc/bmalloc/Allocator.cpp (242414 => 242415)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.24/Source/bmalloc/bmalloc/Allocator.cpp      2019-03-05 08:42:59 UTC (rev 242414)
+++ releases/WebKitGTK/webkit-2.24/Source/bmalloc/bmalloc/Allocator.cpp 2019-03-05 08:43:03 UTC (rev 242415)
</span><span class="lines">@@ -27,7 +27,7 @@
</span><span class="cx"> #include "BAssert.h"
</span><span class="cx"> #include "Chunk.h"
</span><span class="cx"> #include "Deallocator.h"
</span><del>-#include "Environment.h"
</del><ins>+#include "DebugHeap.h"
</ins><span class="cx"> #include "Heap.h"
</span><span class="cx"> #include "PerProcess.h"
</span><span class="cx"> #include "Sizes.h"
</span><span class="lines">@@ -38,9 +38,9 @@
</span><span class="cx"> 
</span><span class="cx"> Allocator::Allocator(Heap& heap, Deallocator& deallocator)
</span><span class="cx">     : m_heap(heap)
</span><ins>+    , m_debugHeap(heap.debugHeap())
</ins><span class="cx">     , m_deallocator(deallocator)
</span><span class="cx"> {
</span><del>-    BASSERT(!PerProcess<Environment>::get()->isDebugHeapEnabled());
</del><span class="cx">     for (size_t sizeClass = 0; sizeClass < sizeClassCount; ++sizeClass)
</span><span class="cx">         m_bumpAllocators[sizeClass].init(objectSize(sizeClass));
</span><span class="cx"> }
</span><span class="lines">@@ -52,6 +52,9 @@
</span><span class="cx"> 
</span><span class="cx"> void* Allocator::tryAllocate(size_t size)
</span><span class="cx"> {
</span><ins>+    if (m_debugHeap)
+        return m_debugHeap->malloc(size);
+
</ins><span class="cx">     if (size <= smallMax)
</span><span class="cx">         return allocate(size);
</span><span class="cx"> 
</span><span class="lines">@@ -75,6 +78,9 @@
</span><span class="cx"> {
</span><span class="cx">     BASSERT(isPowerOfTwo(alignment));
</span><span class="cx"> 
</span><ins>+    if (m_debugHeap)
+        return m_debugHeap->memalign(alignment, size, crashOnFailure);
+
</ins><span class="cx">     if (!size)
</span><span class="cx">         size = alignment;
</span><span class="cx"> 
</span><span class="lines">@@ -101,6 +107,9 @@
</span><span class="cx"> 
</span><span class="cx"> void* Allocator::reallocateImpl(void* object, size_t newSize, bool crashOnFailure)
</span><span class="cx"> {
</span><ins>+    if (m_debugHeap)
+        return m_debugHeap->realloc(object, newSize, crashOnFailure);
+
</ins><span class="cx">     size_t oldSize = 0;
</span><span class="cx">     switch (objectType(m_heap.kind(), object)) {
</span><span class="cx">     case ObjectType::Small: {
</span><span class="lines">@@ -191,6 +200,9 @@
</span><span class="cx"> 
</span><span class="cx"> void* Allocator::allocateSlowCase(size_t size)
</span><span class="cx"> {
</span><ins>+    if (m_debugHeap)
+        return m_debugHeap->malloc(size);
+
</ins><span class="cx">     if (size <= maskSizeClassMax) {
</span><span class="cx">         size_t sizeClass = bmalloc::maskSizeClass(size);
</span><span class="cx">         BumpAllocator& allocator = m_bumpAllocators[sizeClass];
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit224SourcebmallocbmallocAllocatorh"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.24/Source/bmalloc/bmalloc/Allocator.h (242414 => 242415)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.24/Source/bmalloc/bmalloc/Allocator.h        2019-03-05 08:42:59 UTC (rev 242414)
+++ releases/WebKitGTK/webkit-2.24/Source/bmalloc/bmalloc/Allocator.h   2019-03-05 08:43:03 UTC (rev 242415)
</span><span class="lines">@@ -33,6 +33,7 @@
</span><span class="cx"> namespace bmalloc {
</span><span class="cx"> 
</span><span class="cx"> class Deallocator;
</span><ins>+class DebugHeap;
</ins><span class="cx"> class Heap;
</span><span class="cx"> 
</span><span class="cx"> // Per-cache object allocator.
</span><span class="lines">@@ -68,6 +69,7 @@
</span><span class="cx">     std::array<BumpRangeCache, sizeClassCount> m_bumpRangeCaches;
</span><span class="cx"> 
</span><span class="cx">     Heap& m_heap;
</span><ins>+    DebugHeap* m_debugHeap;
</ins><span class="cx">     Deallocator& m_deallocator;
</span><span class="cx"> };
</span><span class="cx"> 
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit224SourcebmallocbmallocCachecpp"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.24/Source/bmalloc/bmalloc/Cache.cpp (242414 => 242415)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.24/Source/bmalloc/bmalloc/Cache.cpp  2019-03-05 08:42:59 UTC (rev 242414)
+++ releases/WebKitGTK/webkit-2.24/Source/bmalloc/bmalloc/Cache.cpp     2019-03-05 08:43:03 UTC (rev 242415)
</span><span class="lines">@@ -25,15 +25,11 @@
</span><span class="cx"> 
</span><span class="cx"> #include "BInline.h"
</span><span class="cx"> #include "Cache.h"
</span><del>-#include "DebugHeap.h"
-#include "Environment.h"
</del><span class="cx"> #include "Heap.h"
</span><span class="cx"> #include "PerProcess.h"
</span><span class="cx"> 
</span><span class="cx"> namespace bmalloc {
</span><span class="cx"> 
</span><del>-static DebugHeap* debugHeapCache { nullptr };
-
</del><span class="cx"> void Cache::scavenge(HeapKind heapKind)
</span><span class="cx"> {
</span><span class="cx">     PerHeapKind<Cache>* caches = PerThread<PerHeapKind<Cache>>::getFastCase();
</span><span class="lines">@@ -46,82 +42,34 @@
</span><span class="cx">     caches->at(heapKind).deallocator().scavenge();
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-static BINLINE DebugHeap* debugHeap()
-{
-    if (debugHeapCache)
-        return debugHeapCache;
-    if (PerProcess<Environment>::get()->isDebugHeapEnabled()) {
-        debugHeapCache = PerProcess<DebugHeap>::get();
-        return debugHeapCache;
-    }
-    return nullptr;
-}
-
</del><span class="cx"> Cache::Cache(HeapKind heapKind)
</span><span class="cx">     : m_deallocator(PerProcess<PerHeapKind<Heap>>::get()->at(heapKind))
</span><span class="cx">     , m_allocator(PerProcess<PerHeapKind<Heap>>::get()->at(heapKind), m_deallocator)
</span><span class="cx"> {
</span><del>-    BASSERT(!PerProcess<Environment>::get()->isDebugHeapEnabled());
</del><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> BNO_INLINE void* Cache::tryAllocateSlowCaseNullCache(HeapKind heapKind, size_t size)
</span><span class="cx"> {
</span><del>-    // FIXME: DebugHeap does not have tryAllocate feature.
-    // https://bugs.webkit.org/show_bug.cgi?id=194837
-    if (auto* heap = debugHeap())
-        return heap->malloc(size);
</del><span class="cx">     return PerThread<PerHeapKind<Cache>>::getSlowCase()->at(mapToActiveHeapKind(heapKind)).allocator().tryAllocate(size);
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> BNO_INLINE void* Cache::allocateSlowCaseNullCache(HeapKind heapKind, size_t size)
</span><span class="cx"> {
</span><del>-    if (auto* heap = debugHeap())
-        return heap->malloc(size);
</del><span class="cx">     return PerThread<PerHeapKind<Cache>>::getSlowCase()->at(mapToActiveHeapKind(heapKind)).allocator().allocate(size);
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-BNO_INLINE void* Cache::tryAllocateSlowCaseNullCache(HeapKind heapKind, size_t alignment, size_t size)
-{
-    if (auto* heap = debugHeap()) {
-        constexpr bool crashOnFailure = false;
-        return heap->memalign(alignment, size, crashOnFailure);
-    }
-    return PerThread<PerHeapKind<Cache>>::getSlowCase()->at(mapToActiveHeapKind(heapKind)).allocator().tryAllocate(alignment, size);
-}
-
</del><span class="cx"> BNO_INLINE void* Cache::allocateSlowCaseNullCache(HeapKind heapKind, size_t alignment, size_t size)
</span><span class="cx"> {
</span><del>-    if (auto* heap = debugHeap()) {
-        constexpr bool crashOnFailure = true;
-        return heap->memalign(alignment, size, crashOnFailure);
-    }
</del><span class="cx">     return PerThread<PerHeapKind<Cache>>::getSlowCase()->at(mapToActiveHeapKind(heapKind)).allocator().allocate(alignment, size);
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> BNO_INLINE void Cache::deallocateSlowCaseNullCache(HeapKind heapKind, void* object)
</span><span class="cx"> {
</span><del>-    if (auto* heap = debugHeap()) {
-        heap->free(object);
-        return;
-    }
</del><span class="cx">     PerThread<PerHeapKind<Cache>>::getSlowCase()->at(mapToActiveHeapKind(heapKind)).deallocator().deallocate(object);
</span><span class="cx"> }
</span><span class="cx"> 
</span><del>-BNO_INLINE void* Cache::tryReallocateSlowCaseNullCache(HeapKind heapKind, void* object, size_t newSize)
-{
-    if (auto* heap = debugHeap()) {
-        constexpr bool crashOnFailure = false;
-        return heap->realloc(object, newSize, crashOnFailure);
-    }
-    return PerThread<PerHeapKind<Cache>>::getSlowCase()->at(mapToActiveHeapKind(heapKind)).allocator().tryReallocate(object, newSize);
-}
-
</del><span class="cx"> BNO_INLINE void* Cache::reallocateSlowCaseNullCache(HeapKind heapKind, void* object, size_t newSize)
</span><span class="cx"> {
</span><del>-    if (auto* heap = debugHeap()) {
-        constexpr bool crashOnFailure = true;
-        return heap->realloc(object, newSize, crashOnFailure);
-    }
</del><span class="cx">     return PerThread<PerHeapKind<Cache>>::getSlowCase()->at(mapToActiveHeapKind(heapKind)).allocator().reallocate(object, newSize);
</span><span class="cx"> }
</span><span class="cx"> 
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit224SourcebmallocbmallocCacheh"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.24/Source/bmalloc/bmalloc/Cache.h (242414 => 242415)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.24/Source/bmalloc/bmalloc/Cache.h    2019-03-05 08:42:59 UTC (rev 242414)
+++ releases/WebKitGTK/webkit-2.24/Source/bmalloc/bmalloc/Cache.h       2019-03-05 08:43:03 UTC (rev 242415)
</span><span class="lines">@@ -56,10 +56,8 @@
</span><span class="cx"> private:
</span><span class="cx">     BEXPORT static void* tryAllocateSlowCaseNullCache(HeapKind, size_t);
</span><span class="cx">     BEXPORT static void* allocateSlowCaseNullCache(HeapKind, size_t);
</span><del>-    BEXPORT static void* tryAllocateSlowCaseNullCache(HeapKind, size_t alignment, size_t);
</del><span class="cx">     BEXPORT static void* allocateSlowCaseNullCache(HeapKind, size_t alignment, size_t);
</span><span class="cx">     BEXPORT static void deallocateSlowCaseNullCache(HeapKind, void*);
</span><del>-    BEXPORT static void* tryReallocateSlowCaseNullCache(HeapKind, void*, size_t);
</del><span class="cx">     BEXPORT static void* reallocateSlowCaseNullCache(HeapKind, void*, size_t);
</span><span class="cx"> 
</span><span class="cx">     Deallocator m_deallocator;
</span><span class="lines">@@ -86,7 +84,7 @@
</span><span class="cx"> {
</span><span class="cx">     PerHeapKind<Cache>* caches = PerThread<PerHeapKind<Cache>>::getFastCase();
</span><span class="cx">     if (!caches)
</span><del>-        return tryAllocateSlowCaseNullCache(heapKind, alignment, size);
</del><ins>+        return allocateSlowCaseNullCache(heapKind, alignment, size);
</ins><span class="cx">     return caches->at(mapToActiveHeapKindAfterEnsuringGigacage(heapKind)).allocator().tryAllocate(alignment, size);
</span><span class="cx"> }
</span><span class="cx"> 
</span><span class="lines">@@ -110,7 +108,7 @@
</span><span class="cx"> {
</span><span class="cx">     PerHeapKind<Cache>* caches = PerThread<PerHeapKind<Cache>>::getFastCase();
</span><span class="cx">     if (!caches)
</span><del>-        return tryReallocateSlowCaseNullCache(heapKind, object, newSize);
</del><ins>+        return reallocateSlowCaseNullCache(heapKind, object, newSize);
</ins><span class="cx">     return caches->at(mapToActiveHeapKindAfterEnsuringGigacage(heapKind)).allocator().tryReallocate(object, newSize);
</span><span class="cx"> }
</span><span class="cx"> 
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit224SourcebmallocbmallocDeallocatorcpp"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.24/Source/bmalloc/bmalloc/Deallocator.cpp (242414 => 242415)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.24/Source/bmalloc/bmalloc/Deallocator.cpp    2019-03-05 08:42:59 UTC (rev 242414)
+++ releases/WebKitGTK/webkit-2.24/Source/bmalloc/bmalloc/Deallocator.cpp       2019-03-05 08:43:03 UTC (rev 242415)
</span><span class="lines">@@ -27,7 +27,7 @@
</span><span class="cx"> #include "BInline.h"
</span><span class="cx"> #include "Chunk.h"
</span><span class="cx"> #include "Deallocator.h"
</span><del>-#include "Environment.h"
</del><ins>+#include "DebugHeap.h"
</ins><span class="cx"> #include "Heap.h"
</span><span class="cx"> #include "Object.h"
</span><span class="cx"> #include "PerProcess.h"
</span><span class="lines">@@ -39,8 +39,13 @@
</span><span class="cx"> 
</span><span class="cx"> Deallocator::Deallocator(Heap& heap)
</span><span class="cx">     : m_heap(heap)
</span><ins>+    , m_debugHeap(heap.debugHeap())
</ins><span class="cx"> {
</span><del>-    BASSERT(!PerProcess<Environment>::get()->isDebugHeapEnabled());
</del><ins>+    if (m_debugHeap) {
+        // Fill the object log in order to disable the fast path.
+        while (m_objectLog.size() != m_objectLog.capacity())
+            m_objectLog.push(nullptr);
+    }
</ins><span class="cx"> }
</span><span class="cx"> 
</span><span class="cx"> Deallocator::~Deallocator()
</span><span class="lines">@@ -50,6 +55,9 @@
</span><span class="cx">     
</span><span class="cx"> void Deallocator::scavenge()
</span><span class="cx"> {
</span><ins>+    if (m_debugHeap)
+        return;
+
</ins><span class="cx">     std::unique_lock<Mutex> lock(Heap::mutex());
</span><span class="cx"> 
</span><span class="cx">     processObjectLog(lock);
</span><span class="lines">@@ -65,6 +73,9 @@
</span><span class="cx"> 
</span><span class="cx"> void Deallocator::deallocateSlowCase(void* object)
</span><span class="cx"> {
</span><ins>+    if (m_debugHeap)
+        return m_debugHeap->free(object);
+
</ins><span class="cx">     if (!object)
</span><span class="cx">         return;
</span><span class="cx"> 
</span></span></pre></div>
<a id="releasesWebKitGTKwebkit224SourcebmallocbmallocDeallocatorh"></a>
<div class="modfile"><h4>Modified: releases/WebKitGTK/webkit-2.24/Source/bmalloc/bmalloc/Deallocator.h (242414 => 242415)</h4>
<pre class="diff"><span>
<span class="info">--- releases/WebKitGTK/webkit-2.24/Source/bmalloc/bmalloc/Deallocator.h      2019-03-05 08:42:59 UTC (rev 242414)
+++ releases/WebKitGTK/webkit-2.24/Source/bmalloc/bmalloc/Deallocator.h 2019-03-05 08:43:03 UTC (rev 242415)
</span><span class="lines">@@ -33,6 +33,7 @@
</span><span class="cx"> 
</span><span class="cx"> namespace bmalloc {
</span><span class="cx"> 
</span><ins>+class DebugHeap;
</ins><span class="cx"> class Heap;
</span><span class="cx"> class Mutex;
</span><span class="cx"> 
</span><span class="lines">@@ -57,6 +58,7 @@
</span><span class="cx">     Heap& m_heap;
</span><span class="cx">     FixedVector<void*, deallocatorLogCapacity> m_objectLog;
</span><span class="cx">     LineCache m_lineCache; // The Heap removes items from this cache.
</span><ins>+    DebugHeap* m_debugHeap;
</ins><span class="cx"> };
</span><span class="cx"> 
</span><span class="cx"> inline bool Deallocator::deallocateFastCase(void* object)
</span></span></pre>
</div>
</div>

</body>
</html>