D7933: feeds.opml is never backed up

Jonathan Marten noreply at phabricator.kde.org
Fri Sep 22 10:05:00 BST 2017


marten created this revision.
marten added a reviewer: KDE PIM.
Restricted Application added a project: KDE PIM.

REVISION SUMMARY
  According to the comments, Part::slotSaveFeedList() is intended to back up the feeds.opml file the first time that it is to be overwritten.  This is a bit ambiguous, but according to the code and the use of the m_backedUpList flag it should happen the first time the file is saved in a run of the Akregator application.  However, this never happens because QFile::copy() will not overwrite an existing file.
  
  The effect of that is that the file will be backed up the first time that Akregator is ever run by a new user, and no backup will then be taken ever again.  Evan that backup is not very useful as it will be a copy of the default feed list.
  
  This change removes the destination file before the backup copy is taken.

TEST PLAN
  Built akregator with this change.  Verified (by checking file times) that a backup of feeds.opml is taken five minutes after Akregator is started and that a new backup is taken for each run.

REPOSITORY
  R201 Akregator

REVISION DETAIL
  https://phabricator.kde.org/D7933

AFFECTED FILES
  src/akregator_part.cpp

To: marten, #kde_pim
Cc: dvasin, winterz, vkrause, mlaurent, knauss, dvratil
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-pim/attachments/20170922/64627bc1/attachment.html>


More information about the kde-pim mailing list