summaryrefslogtreecommitdiffstats
path: root/id3lib
diff options
context:
space:
mode:
author Eric Hameleers <alien@slackware.com>2008-06-21 19:11:22 +0000
committer Eric Hameleers <alien@slackware.com>2008-06-21 19:11:22 +0000
commit2d6a91cebc4cf8d22485189914b80c368101001a (patch)
tree03cdc624372e754f64243fc99560292c83eb2c92 /id3lib
parentfc889d3b433307a125c02d5c268f4ce8388d57d4 (diff)
downloadasb-2d6a91cebc4cf8d22485189914b80c368101001a.tar.gz
asb-2d6a91cebc4cf8d22485189914b80c368101001a.tar.xz
Initial revision
Diffstat (limited to 'id3lib')
-rw-r--r--id3lib/build/id3lib_utf8.patch39
1 files changed, 39 insertions, 0 deletions
diff --git a/id3lib/build/id3lib_utf8.patch b/id3lib/build/id3lib_utf8.patch
new file mode 100644
index 00000000..b05d2cf2
--- /dev/null
+++ b/id3lib/build/id3lib_utf8.patch
@@ -0,0 +1,39 @@
+diff -ruN id3lib-3.8.3.orig/ChangeLog id3lib-3.8.3/ChangeLog
+--- id3lib-3.8.3.orig/ChangeLog 2003-03-02 01:23:00.000000000 +0100
++++ id3lib-3.8.3/ChangeLog 2006-02-22 00:33:59.946214472 +0100
+@@ -1,3 +1,8 @@
++2006-02-17 Jerome Couderc
++
++ * Patch from Spoon to fix UTF-16 writing bug
++ http://sourceforge.net/tracker/index.php?func=detail&aid=1016290&group_id=979&atid=300979
++
+ 2003-03-02 Sunday 17:38 Thijmen Klok <thijmen@id3lib.org>
+
+ * THANKS (1.20): added more people
+diff -ruN id3lib-3.8.3.orig/src/io_helpers.cpp id3lib-3.8.3/src/io_helpers.cpp
+--- id3lib-3.8.3.orig/src/io_helpers.cpp 2003-03-02 01:23:00.000000000 +0100
++++ id3lib-3.8.3/src/io_helpers.cpp 2006-02-22 00:35:02.926639992 +0100
+@@ -363,11 +363,22 @@
+ // Write the BOM: 0xFEFF
+ unicode_t BOM = 0xFEFF;
+ writer.writeChars((const unsigned char*) &BOM, 2);
++ // Patch from Spoon : 2004-08-25 14:17
++ // http://sourceforge.net/tracker/index.php?func=detail&aid=1016290&group_id=979&atid=300979
++ // Wrong code
++ //for (size_t i = 0; i < size; i += 2)
++ //{
++ // unicode_t ch = (data[i] << 8) | data[i+1];
++ // writer.writeChars((const unsigned char*) &ch, 2);
++ //}
++ // Right code
++ unsigned char *pdata = (unsigned char *) data.c_str();
+ for (size_t i = 0; i < size; i += 2)
+ {
+- unicode_t ch = (data[i] << 8) | data[i+1];
++ unicode_t ch = (pdata[i] << 8) | pdata[i+1];
+ writer.writeChars((const unsigned char*) &ch, 2);
+ }
++ // End patch
+ }
+ return writer.getCur() - beg;
+ }