Bugzilla – Attachment 49427 Details for
Bug 116126
amarok displays garbage for ipod playlist
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
IDP Log In
|
Forgot Password
[patch]
patch
amarok-itunes-fix.diff (text/plain), 1.27 KB, created by
Dirk Mueller
on 2005-09-09 15:26:18 UTC
(
hide
)
Description:
patch
Filename:
MIME Type:
Creator:
Dirk Mueller
Created:
2005-09-09 15:26:18 UTC
Size:
1.27 KB
patch
obsolete
>Index: src/ipod/itunesdb/itunesdbparser.cpp >=================================================================== >--- src/ipod/itunesdb/itunesdbparser.cpp (revision 455555) >+++ src/ipod/itunesdb/itunesdbparser.cpp (working copy) >@@ -126,21 +126,24 @@ > stream >> blocklen; > > uint datalen = blocklen - 40; >- QByteArray buffer( datalen+2 ); > > stream >> type; > >- seekRelative(stream, 24); // skip stuff >- stream.readRawBytes(buffer.data(), datalen); >- buffer[datalen] = 0; >- buffer[datalen + 1] = 0; >- > if( type == itunesdb::MHOD_PLAYLIST) > break; // ignore > >+ unsigned short* buffer = new unsigned short[ datalen+2/2]; >+ >+ seekRelative(stream, 24); // skip stuff >+ for ( int i = 0; i < datalen/2; ++i ) >+ stream >> ( Q_UINT16 ) buffer[ i ]; >+ >+ buffer[datalen/2]= 0; >+ > if( listitem != NULL) >- listitem->setItemProperty( QString::fromUcs2( (unsigned short *)buffer.data()), (ItemProperty)type); >+ listitem->setItemProperty( QString::fromUcs2(buffer), (ItemProperty)type); > } >+ delete[] buffer; > break; > > case 0x706C686D: { // mhlp
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
Actions:
View
|
Diff
Attachments on
bug 116126
:
49402
| 49427