<table><tr><td style="">rthomsen created this revision.<br />rthomsen added a reviewer: elvisangelaccio.<br />rthomsen set the repository for this revision to rARK Ark.<br />rthomsen added a project: Ark.<br />Restricted Application added a subscriber: kde-utils-devel.
</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/D3273" rel="noreferrer">View Revision</a></tr></table><br /><div><strong>REVISION SUMMARY</strong><div><p>When adding files to an archive with <tt style="background: #ebebeb; font-size: 13px;">libarchiveplugin</tt> and the destination files already exist (so they get overwritten), the <tt style="background: #ebebeb; font-size: 13px;">entry</tt> signal is still emitted and hence <tt style="background: #ebebeb; font-size: 13px;">m_numberOfEntries</tt> gets wrongfully incremented. This diff decrements the counter when an entry already exists.</p>
<p>Overwriting of entries is disabled for <tt style="background: #ebebeb; font-size: 13px;">CopyJob</tt> and <tt style="background: #ebebeb; font-size: 13px;">MoveJob</tt>, so there is no problem in those cases.</p></div></div><br /><div><strong>TEST PLAN</strong><div><p>A test case was added to <tt style="background: #ebebeb; font-size: 13px;">AddTest</tt> which detects the wrong counter when overwriting an entry.</p></div></div><br /><div><strong>REPOSITORY</strong><div><div>rARK Ark</div></div></div><br /><div><strong>REVISION DETAIL</strong><div><a href="https://phabricator.kde.org/D3273" rel="noreferrer">https://phabricator.kde.org/D3273</a></div></div><br /><div><strong>AFFECTED FILES</strong><div><div>autotests/kerfuffle/addtest.cpp<br />
plugins/libarchive/readwritelibarchiveplugin.cpp</div></div></div><br /><div><strong>EMAIL PREFERENCES</strong><div><a href="https://phabricator.kde.org/settings/panel/emailpreferences/" rel="noreferrer">https://phabricator.kde.org/settings/panel/emailpreferences/</a></div></div><br /><div><strong>To: </strong>rthomsen, elvisangelaccio<br /><strong>Cc: </strong>kde-utils-devel, tctara<br /></div>