<table><tr><td style="">zzag updated this revision to Diff 74504.<br />zzag retitled this revision from "[kstyle] Use guarded pointers to store shadows" to "[kstyle] Unregister a shadow when it's destroyed".<br />zzag edited the summary of this revision. <a href="https://phabricator.kde.org/transactions/detail/PHID-XACT-DREV-m3qc7hu5fkzcx6r/">(Show Details)</a><br />zzag added a comment.
</td><a style="text-decoration: none; padding: 4px 8px; margin: 0 8px 8px; float: right; color: #464C5C; font-weight: bold; border-radius: 3px; background-color: #F7F7F9; background-image: linear-gradient(to bottom,#fff,#f1f0f1); display: inline-block; border: 1px solid rgba(71,87,120,.2);" href="https://phabricator.kde.org/D26966">View Revision</a></tr></table><br /><div><div><p>Re-title and edit summary.</p></div></div><br /><div><strong>CHANGES TO REVISION SUMMARY</strong><div><div style="white-space: pre-wrap; color: #74777D;">Since <span style="padding: 0 2px; color: #333333; background: rgba(151, 234, 151, .6);">lifetime of </span>a KWindowShadow is <span style="padding: 0 2px; color: #333333; background: rgba(251, 175, 175, .7);">a child of QWindow, we ne</span><span style="padding: 0 2px; color: #333333; background: rgba(151, 234, 151, .6);">not strictly bound</span>ed to <span style="padding: 0 2px; color: #333333; background: rgba(251, 175, 175, .7);">use a guarded</span><span style="padding: 0 2px; color: #333333; background: rgba(151, 234, 151, .6);">lifetime</span><br />
<span style="padding: 0 2px; color: #333333; background: rgba(251, 175, 175, .7);">pointer to store the shadow in order</span><span style="padding: 0 2px; color: #333333; background: rgba(151, 234, 151, .6);">of the associated widget, we need</span> to <span style="padding: 0 2px; color: #333333; background: rgba(251, 175, 175, .7);">prevent accessing or deleting</span><span style="padding: 0 2px; color: #333333; background: rgba(151, 234, 151, .6);">unregister the shadow when it's</span><br />
<span style="padding: 0 2px; color: #333333; background: rgba(251, 175, 175, .7);">dangling pointers in ShadowHelper::_shadows. It's quite possible that</span><span style="padding: 0 2px; color: #333333; background: rgba(151, 234, 151, .6);">destroyed in order to prevent accessing or deleting dangling pointers</span><br />
<span style="padding: 0 2px; color: #333333; background: rgba(251, 175, 175, .7);">one could destroy the associated widget and with it the QWindow</span><span style="padding: 0 2px; color: #333333; background: rgba(151, 234, 151, .6);">afterwards</span>.</div></div></div><br /><div><strong>REPOSITORY</strong><div><div>R31 Breeze</div></div></div><br /><div><strong>CHANGES SINCE LAST UPDATE</strong><div><a href="https://phabricator.kde.org/D26966?vs=74502&id=74504">https://phabricator.kde.org/D26966?vs=74502&id=74504</a></div></div><br /><div><strong>BRANCH</strong><div><div>fix-crash</div></div></div><br /><div><strong>REVISION DETAIL</strong><div><a href="https://phabricator.kde.org/D26966">https://phabricator.kde.org/D26966</a></div></div><br /><div><strong>AFFECTED FILES</strong><div><div>kstyle/breezeshadowhelper.cpp</div></div></div><br /><div><strong>To: </strong>zzag, Plasma, broulik<br /><strong>Cc: </strong>apol, plasma-devel, Orage, LeGast00n, The-Feren-OS-Dev, jraleigh, zachus, fbampaloukas, GB_2, ragreen, ZrenBot, ngraham, alexeymin, himcesjf, lesliezhai, ali-mohamed, jensreuterberg, abetts, sebas, ahiemstra, mart<br /></div>