<html>
<head>
<base href="https://bugs.webkit.org/" />
</head>
<body><span class="vcard"><a class="email" href="mailto:mcatanzaro@igalia.com" title="Michael Catanzaro <mcatanzaro@igalia.com>"> <span class="fn">Michael Catanzaro</span></a>
</span> changed
<a class="bz_bug_link
bz_status_NEW "
title="NEW - Leak in WebContextInjectedBundleClient::getInjectedBundleInitializationUserData"
href="https://bugs.webkit.org/show_bug.cgi?id=148769">bug 148769</a>
<br>
<table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>What</th>
<th>Removed</th>
<th>Added</th>
</tr>
<tr>
<td style="text-align:right;">CC</td>
<td>
</td>
<td>mcatanzaro@igalia.com
</td>
</tr>
<tr>
<td style="text-align:right;">Summary</td>
<td>UI process leaks InjectedBundleInitializationUserData
</td>
<td>Leak in WebContextInjectedBundleClient::getInjectedBundleInitializationUserData
</td>
</tr></table>
<p>
<div>
<b><a class="bz_bug_link
bz_status_NEW "
title="NEW - Leak in WebContextInjectedBundleClient::getInjectedBundleInitializationUserData"
href="https://bugs.webkit.org/show_bug.cgi?id=148769#c2">Comment # 2</a>
on <a class="bz_bug_link
bz_status_NEW "
title="NEW - Leak in WebContextInjectedBundleClient::getInjectedBundleInitializationUserData"
href="https://bugs.webkit.org/show_bug.cgi?id=148769">bug 148769</a>
from <span class="vcard"><a class="email" href="mailto:mcatanzaro@igalia.com" title="Michael Catanzaro <mcatanzaro@igalia.com>"> <span class="fn">Michael Catanzaro</span></a>
</span></b>
<pre>(In reply to <a href="show_bug.cgi?id=148769#c1">comment #1</a>)
<span class="quote">> Adopting the pointer into the PassRefPtr in
> WebContextInjectedBundleClient::getInjectedBundleInitializationUserData()
> would probably fix the leak.</span >
Yes, this fixes it:
- return toImpl(m_client.getInjectedBundleInitializationUserData(toAPI(processPool), m_client.base.clientInfo));
+ return adoptRef(toImpl(m_client.getInjectedBundleInitializationUserData(toAPI(processPool), m_client.base.clientInfo));
A clue was that the result of toImpl was adopted one function up.
(Feel free to submit the patch if you want, since you found it; otherwise I will.)</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are the assignee for the bug.</li>
</ul>
</body>
</html>