Skip to content
  • Friedrich W. H. Kossebau's avatar
    Fix double-deletion crash on destruction of KisNode with KisNodeProgressProxy · ea7592e9
    Friedrich W. H. Kossebau authored
    Summary:
    The emission of the signal KisNodeProgressProxy::percentageChanged due to
    KisBusyProgressIndicator::endUpdatesBeforeDestroying()
    KisBusyProgressIndicator::Private::stopProgressReport()
    KisNodeProgressProxy::setRange(int, int)
    resulted in a temporary KisNodeSP being created, which called ref() and
    deref() on the KisNode object, whose KisShared part already was at 0
    ref count, which results in deref() to trigger another delete call
    on the KisNode.
    
    BUG: 363416
    BUG: 363470
    
    Fixes T2393
    
    Test Plan: KisFileLayerTest no longer fails, other tests still as before.
    
    Reviewers: #krita:_next, rempt, dkazakov
    
    Differential Revision: https://phabricator.kde.org/D1695
    ea7592e9