Binary incompatibility issue in JuK saved data

Michael Pyne mpyne at purinchu.net
Tue Jan 8 05:04:42 GMT 2008


On Monday 07 January 2008, Michael Pyne wrote:
> To cut a long story short however, unless anyone has a better idea my
> intention is to:
>
> * Bump the JuK version encoded in the playlists file and enforce a specific
> QDataStream version.
> * Read in the files encoded with the KDE 3.5/4.0.0 version as if they were
> saved by Qt 3.3, and add sanity checking checks to force trying to load
> using Qt 4 if that doesn't work.  I can't guarantee that this will reliably
> allow JuK in KDE 4.1 or 4.0.1 to load files from 4.0.0 but I think it will
> at least work in most cases.
>
> I can have the patch developed tomorrow (it's basically just adding
> QDataStream::setVersion() calls and bumping the version JuK saves the file
> under) but I just want to get the problem out there so people know.

The attached patch implements most of this:

* It loads the Qt 3.3-saved playlists and cache fine.
* It saves it out using Qt 4.3 binary encoding (even once we use Qt 4.4)
* It loads the Qt 4.3-saved playlists and cache fine.
* It will not load playlists or cache saved using KDE 4.0.0 yet until I add 
error checking to some of the underlying operator>>() for the various 
playlists.  This is because the playlist and cache versions encoded in JuK 
3.5 were shared with 4.0.0 so I cannot distinguish between the two without 
much more sanity checking.

Regards,
 - Michael Pyne
-------------- next part --------------
A non-text attachment was scrubbed...
Name: juk-fix-BIC-with-kde3.patch
Type: text/x-diff
Size: 4023 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20080108/ea6eb0dd/attachment.patch>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part.
URL: <http://mail.kde.org/pipermail/kde-core-devel/attachments/20080108/ea6eb0dd/attachment.sig>


More information about the kde-core-devel mailing list