[PATCH] juk: save collection list cache on exit

Γιώργος Κυλάφας (Giorgos Kylafas) gekylafas at gmail.com
Tue Jun 7 12:31:24 BST 2011


Στις 3 Ιουνίου 2011 2:35 π.μ., ο χρήστης Γιώργος Κυλάφας (Giorgos
Kylafas) <gekylafas at gmail.com> έγραψε:
> Hi all,
>
> I have noticed a problem about the collection list cache saving,
> depending on how JuK is terminated. There are three possibilities:
>
> 1. File->Quit: [...] JuK::slotQuit and JuK::queryExit
> 2. Close window: [...] queryExit
> 3. RMB in System Tray->Quit: [...] queryExit
>
> Since only queryExit is called in every case, the obvious solution
> would be to move JuK::saveConfig and Cache::save there and only there,
> as per the attached file.
> However, maybe the rest of the code in slotQuit should be called in
> all three cases as well, which means there need to be additional
> changes. Or I am missing something else entirely. :-)

I have been testing the above change for the last few days and the
collection list cache is always saved/restored properly. :-)

However, in case 2 (closing the window), JuK crashes if it is playing
a file at the time, with or without the change.
On retrospect, this is reasonable since the cause of the crash is only
dealt with in JuK::slotQuit, which is not executed when closing the
JuK window.

So, I updated the patch to the one attached here. With this version,
the cache is saved/restored properly and I experience no crashes no
matter how I exit the application.

However, I would like a second opinion before committing this. At the
least, I am thinking whether it should be broken up to two patches,
one dealing with the crash and the other with the cache saving.

Regards,

-- 
Γιώργος Κυλάφας (Giorgos Kylafas)
http://en.wikipedia.org/wiki/Posting_style#Inline_replying
-------------- next part --------------
A non-text attachment was scrubbed...
Name: save-cache-on-quit.patch
Type: text/x-diff
Size: 2356 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-multimedia/attachments/20110607/27e333c7/attachment.patch>
-------------- next part --------------
_______________________________________________
kde-multimedia mailing list
kde-multimedia at kde.org
https://mail.kde.org/mailman/listinfo/kde-multimedia


More information about the kde-multimedia mailing list