diff options
author | Patrick J Volkerding <volkerdi@slackware.com> | 2018-05-28 19:12:29 +0000 |
---|---|---|
committer | Eric Hameleers <alien@slackware.com> | 2018-05-31 23:39:35 +0200 |
commit | 646a5c1cbfd95873950a87b5f75d52073a967023 (patch) | |
tree | b8b8d2ab3b0d432ea69ad1a64d1c789649d65020 /source/l/id3lib | |
parent | d31c50870d0bee042ce660e445c9294a59a3a65b (diff) | |
download | current-646a5c1cbfd95873950a87b5f75d52073a967023.tar.gz current-646a5c1cbfd95873950a87b5f75d52073a967023.tar.xz |
Mon May 28 19:12:29 UTC 201820180528191229
a/pkgtools-15.0-noarch-13.txz: Rebuilt.
installpkg: default line length for --terselength is the number of columns.
removepkg: added --terse mode.
upgradepkg: default line length for --terselength is the number of columns.
upgradepkg: accept -option in addition to --option.
ap/vim-8.1.0026-x86_64-1.txz: Upgraded.
d/bison-3.0.5-x86_64-1.txz: Upgraded.
e/emacs-26.1-x86_64-1.txz: Upgraded.
kde/kopete-4.14.3-x86_64-8.txz: Rebuilt.
Recompiled against libidn-1.35.
n/conntrack-tools-1.4.5-x86_64-1.txz: Upgraded.
n/libnetfilter_conntrack-1.0.7-x86_64-1.txz: Upgraded.
n/libnftnl-1.1.0-x86_64-1.txz: Upgraded.
n/links-2.16-x86_64-2.txz: Rebuilt.
Rebuilt to enable X driver for -g mode.
n/lynx-2.8.9dev.19-x86_64-1.txz: Upgraded.
n/nftables-0.8.5-x86_64-1.txz: Upgraded.
n/p11-kit-0.23.11-x86_64-1.txz: Upgraded.
n/ulogd-2.0.7-x86_64-1.txz: Upgraded.
n/whois-5.3.1-x86_64-1.txz: Upgraded.
xap/network-manager-applet-1.8.12-x86_64-1.txz: Upgraded.
xap/vim-gvim-8.1.0026-x86_64-1.txz: Upgraded.
Diffstat (limited to 'source/l/id3lib')
-rwxr-xr-x | source/l/id3lib/id3lib.SlackBuild | 171 | ||||
-rw-r--r-- | source/l/id3lib/patches/id3lib.c_wrapper.patch | 58 | ||||
-rw-r--r-- | source/l/id3lib/patches/id3lib.cppheaders.patch | 22 | ||||
-rw-r--r-- | source/l/id3lib/patches/id3lib.manpages.patch | 198 | ||||
-rw-r--r-- | source/l/id3lib/patches/id3lib.mkstemp.patch | 54 | ||||
-rw-r--r-- | source/l/id3lib/patches/id3lib.nullpointer_check.patch | 12 | ||||
-rw-r--r-- | source/l/id3lib/patches/id3lib.utf8_writing.patch | 38 | ||||
-rw-r--r-- | source/l/id3lib/patches/id3lib.vbr_stack_smash.patch | 19 | ||||
-rw-r--r-- | source/l/id3lib/slack-desc | 19 |
9 files changed, 591 insertions, 0 deletions
diff --git a/source/l/id3lib/id3lib.SlackBuild b/source/l/id3lib/id3lib.SlackBuild new file mode 100755 index 000000000..ccae5744f --- /dev/null +++ b/source/l/id3lib/id3lib.SlackBuild @@ -0,0 +1,171 @@ +#!/bin/bash + +# Copyright 2018 Patrick J. Volkerding, Sebeka, Minnesota, USA +# All rights reserved. +# +# Redistribution and use of this script, with or without modification, is +# permitted provided that the following conditions are met: +# +# 1. Redistributions of this script must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# +# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED +# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO +# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; +# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, +# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR +# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF +# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +cd $(dirname $0) ; CWD=$(pwd) + +PKGNAM=id3lib +VERSION=${VERSION:-$(echo $PKGNAM-*.tar.?z | rev | cut -f 3- -d . | cut -f 1 -d - | rev)} +BUILD=${BUILD:-2} + +# Automatically determine the architecture we're building on: +if [ -z "$ARCH" ]; then + case "$(uname -m)" in + i?86) ARCH=i586 ;; + arm*) readelf /usr/bin/file -A | egrep -q "Tag_CPU.*[4,5]" && ARCH=arm || ARCH=armv7hl ;; + # Unless $ARCH is already set, use uname -m for all other archs: + *) ARCH=$(uname -m) ;; + esac + export ARCH +fi + +# If the variable PRINT_PACKAGE_NAME is set, then this script will report what +# the name of the created package would be, and then exit. This information +# could be useful to other scripts. +if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then + echo "$PKGNAM-$VERSION-$ARCH-$BUILD.txz" + exit 0 +fi + +NUMJOBS=${NUMJOBS:-" -j7 "} + +if [ "$ARCH" = "i586" ]; then + SLKCFLAGS="-O2 -march=i586 -mtune=i686" + LIBDIRSUFFIX="" +elif [ "$ARCH" = "i686" ]; then + SLKCFLAGS="-O2 -march=i686" + LIBDIRSUFFIX="" +elif [ "$ARCH" = "s390" ]; then + SLKCFLAGS="-O2" + LIBDIRSUFFIX="" +elif [ "$ARCH" = "x86_64" ]; then + SLKCFLAGS="-O2 -fPIC" + LIBDIRSUFFIX="64" +elif [ "$ARCH" = "armv7hl" ]; then + SLKCFLAGS="-O3 -march=armv7-a -mfpu=vfpv3-d16" + LIBDIRSUFFIX="" +else + SLKCFLAGS="-O2" + LIBDIRSUFFIX="" +fi + +TMP=${TMP:-/tmp} +PKG=$TMP/package-$PKGNAM + +rm -rf $PKG +mkdir -p $TMP $PKG + +cd $TMP +rm -rf $PKGNAM-$VERSION +tar xvf $CWD/$PKGNAM-$VERSION.tar.?z || exit 1 +cd $PKGNAM-$VERSION || exit 1 + +# Patches obtained from Arch who obtained them from Debian and elsewhere - +# Use proper C++ headers: +zcat $CWD/patches/id3lib.cppheaders.patch.gz | patch -p1 --verbose || exit 1 +# Add man pages: +zcat $CWD/patches/id3lib.manpages.patch.gz | patch -p1 --verbose || exit 1 +# Write UTF8/UTF16 characters correctly: +zcat $CWD/patches/id3lib.utf8_writing.patch.gz | patch -p1 --verbose || exit 1 +# Securely use mkstemp: +zcat $CWD/patches/id3lib.mkstemp.patch.gz | patch -p1 --verbose || exit 1 +# Add C wrapper functions for field encoding: +zcat $CWD/patches/id3lib.c_wrapper.patch.gz | patch -p1 --verbose || exit 1 +# Add a null pointer check: +zcat $CWD/patches/id3lib.nullpointer_check.patch.gz | patch -p1 --verbose || exit 1 +# Fix stack smash crashes when reading VBR MP3: +zcat $CWD/patches/id3lib.vbr_stack_smash.patch.gz | patch -p1 --verbose || exit 1 + +# iomanip.h is obsolete; use the standard C++ header: +sed -e "s%iomanip.h%iomanip%g" -i configure + +chown -R root:root . +find . \ + \( -perm 777 -o -perm 775 -o -perm 711 -o -perm 555 -o -perm 511 \) \ + -exec chmod 755 {} \; -o \ + \( -perm 666 -o -perm 664 -o -perm 600 -o -perm 444 -o -perm 440 -o -perm 400 \) \ + -exec chmod 644 {} \; + +# Configure: +CFLAGS="$SLKCFLAGS" \ +./configure \ + --prefix=/usr \ + --sysconfdir=/etc \ + --libdir=/usr/lib${LIBDIRSUFFIX} \ + --localstatedir=/var \ + --mandir=/usr/man \ + --enable-static=no \ + --enable-debug=no \ + --build=$ARCH-slackware-linux || exit 1 + +# Build and install: +make $NUMJOBS || make || exit 1 +make install DESTDIR=$PKG || exit 1 + +# Don't ship .la files: +rm -f $PKG/usr/lib${LIBDIRSUFFIX}/*.la + +# Strip binaries: +( cd $PKG + find . | xargs file | grep "executable" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null + find . | xargs file | grep "shared object" | grep ELF | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null +) + +# Add a documentation directory: +mkdir -p $PKG/usr/doc/${PKGNAM}-$VERSION +cp -a \ + AUTHORS COPYING* HISTORY NEWS README* THANKS TODO \ + doc/id3v2.3.0.txt doc/musicmatch.txt \ + $PKG/usr/doc/${PKGNAM}-$VERSION + +# Install man pages: +mkdir -p $PKG/usr/man/man1 +cp -a doc/man/* $PKG/usr/man/man1 + +# Compress and link manpages, if any: +if [ -d $PKG/usr/man ]; then + ( cd $PKG/usr/man + for manpagedir in $(find . -type d -name "man*") ; do + ( cd $manpagedir + for eachpage in $( find . -type l -maxdepth 1 | grep -v '\.gz$') ; do + ln -s $( readlink $eachpage ).gz $eachpage.gz + rm $eachpage + done + gzip -9 *.? + ) + done + ) +fi + +# If there's a ChangeLog, installing at least part of the recent history +# is useful, but don't let it get totally out of control: +if [ -r ChangeLog ]; then + DOCSDIR=$(echo $PKG/usr/doc/${PKGNAM}-$VERSION) + cat ChangeLog | head -n 1000 > $DOCSDIR/ChangeLog + touch -r ChangeLog $DOCSDIR/ChangeLog +fi + +mkdir -p $PKG/install +cat $CWD/slack-desc > $PKG/install/slack-desc + +cd $PKG +/sbin/makepkg -l y -c n $TMP/$PKGNAM-$VERSION-$ARCH-$BUILD.txz + diff --git a/source/l/id3lib/patches/id3lib.c_wrapper.patch b/source/l/id3lib/patches/id3lib.c_wrapper.patch new file mode 100644 index 000000000..d72e81c0e --- /dev/null +++ b/source/l/id3lib/patches/id3lib.c_wrapper.patch @@ -0,0 +1,58 @@ +This patch adds C wrapper functions for field encoding. + +It was first introduced in version 3.8.3-8 and fixes +http://bugs.debian.org/281292 +--- a/include/id3.h ++++ b/include/id3.h +@@ -104,6 +104,9 @@ + ID3_C_EXPORT void CCONV ID3Field_GetBINARY (const ID3Field *field, uchar *buffer, size_t buffLength); + ID3_C_EXPORT void CCONV ID3Field_FromFile (ID3Field *field, const char *fileName); + ID3_C_EXPORT void CCONV ID3Field_ToFile (const ID3Field *field, const char *fileName); ++ ID3_C_EXPORT bool CCONV ID3Field_SetEncoding (ID3Field *field, ID3_TextEnc enc); ++ ID3_C_EXPORT ID3_TextEnc CCONV ID3Field_GetEncoding (const ID3Field *field); ++ ID3_C_EXPORT bool CCONV ID3Field_IsEncodable (const ID3Field *field); + + /* field-info wrappers */ + ID3_C_EXPORT char* CCONV ID3FrameInfo_ShortName (ID3_FrameID frameid); +--- a/src/c_wrapper.cpp ++++ b/src/c_wrapper.cpp +@@ -681,6 +681,39 @@ + } + } + ++ ID3_C_EXPORT bool CCONV ++ ID3Field_SetEncoding(ID3Field *field, ID3_TextEnc enc) ++ { ++ bool changed = false; ++ if (field) ++ { ++ ID3_CATCH(changed = reinterpret_cast<ID3_Field *>(field)->SetEncoding(enc)); ++ } ++ return changed; ++ } ++ ++ ID3_C_EXPORT ID3_TextEnc CCONV ++ ID3Field_GetEncoding(const ID3Field *field) ++ { ++ ID3_TextEnc enc = ID3TE_NONE; ++ if (field) ++ { ++ ID3_CATCH(enc = reinterpret_cast<const ID3_Field *>(field)->GetEncoding()); ++ } ++ return enc; ++ } ++ ++ ID3_C_EXPORT bool CCONV ++ ID3Field_IsEncodable(const ID3Field *field) ++ { ++ bool isEncodable = false; ++ if (field) ++ { ++ ID3_CATCH(isEncodable = reinterpret_cast<const ID3_Field *>(field)->IsEncodable()); ++ } ++ return isEncodable; ++ } ++ + #ifdef __cplusplus + } + #endif /* __cplusplus */ diff --git a/source/l/id3lib/patches/id3lib.cppheaders.patch b/source/l/id3lib/patches/id3lib.cppheaders.patch new file mode 100644 index 000000000..a9b45ab02 --- /dev/null +++ b/source/l/id3lib/patches/id3lib.cppheaders.patch @@ -0,0 +1,22 @@ +This patch imports the proper C++ headers +--- a/include/id3/id3lib_strings.h ++++ b/include/id3/id3lib_strings.h +@@ -30,6 +30,7 @@ + #define _ID3LIB_STRINGS_H_ + + #include <string> ++#include <cstring> + + #if (defined(__GNUC__) && (__GNUC__ >= 3) || (defined(_MSC_VER) && _MSC_VER > 1000)) + namespace std +--- a/include/id3/writers.h ++++ b/include/id3/writers.h +@@ -30,7 +30,7 @@ + + #include "id3/writer.h" + #include "id3/id3lib_streams.h" +-//#include <string.h> ++#include <cstring> + + class ID3_CPP_EXPORT ID3_OStreamWriter : public ID3_Writer + { diff --git a/source/l/id3lib/patches/id3lib.manpages.patch b/source/l/id3lib/patches/id3lib.manpages.patch new file mode 100644 index 000000000..cebf3d4d4 --- /dev/null +++ b/source/l/id3lib/patches/id3lib.manpages.patch @@ -0,0 +1,198 @@ +This patch adds debian-made man pages +--- /dev/null ++++ b/doc/man/id3info.1 +@@ -0,0 +1,31 @@ ++.TH ID3INFO 1 "May 2000" local "User Command" ++.SH NAME ++id3info \- Display id3 tag information. ++.SH SYNOPSIS ++.B id3info ++.RB [ ++.I OPTION ++.RB ] ++.RB [ ++.I FILE ++.RB ] ++.br ++.SH DESCRIPTION ++.B Id3info ++displays both the id3v1 and id3v2 tag information for a file. ++Id3info will not differentiate between the two types of tags. ++.SH OPTIONS ++.TP ++.B \-h, \-\-help ++Display help and exit ++.TP ++.B \-v, \-\-version ++Display version information and exit ++.SH SEE ALSO ++id3convert(1), id3tag(1), id3v2(1) ++.SH AUTHOR ++.B id3lib ++was originally designed and implemented by Dirk Mahoney and is ++maintained by Scott Thomas Haug <sth2@cs.wustl.edu>. Manual page written for ++Debian GNU/Linux by Robert Woodcock <rcw@debian.org>. ++ +--- /dev/null ++++ b/doc/man/id3tag.1 +@@ -0,0 +1,69 @@ ++.TH ID3TAG 1 "May 2000" local "User Command" ++.SH NAME ++id3tag \- Tags an mp3 file with id3v1 and/or id3v2 tags. ++.SH SYNOPSIS ++.B id3tag ++.RB [ ++.I OPTION ++.RB ] ... ++.RB [ ++.I FILE ++.RB ] ... ++.br ++.SH DESCRIPTION ++.B Id3tag ++will render both types of tag by default. Only the last ++tag type indicated in the option list will be used. Non- ++rendered will remain unchanged in the original file. Will ++also parse and convert Lyrics3 v2.0 frames, but will not ++render them. ++ ++.SH OPTIONS ++.TP ++.B \-1, \-\-v1tag ++Render only the id3v1 tag ++.TP ++.B \-2, \-\-v2tag ++Render only the id3v2 tag ++.TP ++.B \-h, \-\-help ++Display help and exit ++.TP ++.B \-v, \-\-version ++Display version information and exit ++.TP ++.B \-a, \-\-artist ARTIST ++Set the artist information ++.TP ++.B \-s, \-\-song SONG ++Set the song title information ++.TP ++.B \-A, \-\-album ALBUM ++Set the album title information ++.TP ++.B \-c, \-\-comment COMMENT ++Set the comment information ++.TP ++.B \-C, \-\-desc DESCRIPTION ++Set the comment description ++.TP ++.B \-g, \-\-genre num ++Set the genre number ++.TP ++.B \-y, \-\-year num ++Set the year ++.TP ++.B \-t, \-\-track num ++Set the track number ++.TP ++.B \-T, \-\-total num ++Set the total number of tracks on the album ++ ++.SH SEE ALSO ++id3convert(1), id3info(1), id3v2(1) ++.SH AUTHOR ++.B id3lib ++was originally designed and implemented by Dirk Mahoney and is ++maintained by Scott Thomas Haug <sth2@cs.wustl.edu>. Manual page written for ++Debian GNU/Linux by Robert Woodcock <rcw@debian.org>. ++ +--- /dev/null ++++ b/doc/man/id3convert.1 +@@ -0,0 +1,47 @@ ++.TH ID3CONVERT 1 "May 2000" local "User Command" ++.SH NAME ++id3convert \- Converts between id3v1 and id3v2 tags of an mp3 file. ++.SH SYNOPSIS ++.B id3convert ++.RB [ ++.I OPTION ++.RB ] ++.RB [ ++.I FILE ++.RB ] ++.br ++.SH DESCRIPTION ++.B Id3convert ++converts between id3v1 and id3v2 tags of an mp3 file. Id3convert will render ++both types of tag by default. Only the last tag type indicated in the option ++list will be used. Non-rendered tags will remain unchanged in the original ++file. Id3convert will also parse and convert Lyrics3 v2.0 frames, but will ++not render them. ++ ++.SH OPTIONS ++.TP ++.B \-1, \-\-v1tag ++Render only the id3v1 tag ++.TP ++.B \-2, \-\-v2tag ++Render only the id3v2 tag ++.TP ++.B \-s, \-\-strip ++Strip, rather than render, the tags ++.TP ++.B \-p, \-\-padding ++Use padding in the tag ++.TP ++.B \-h, \-\-help ++Display help and exit ++.TP ++.B \-v, \-\-version ++Display version information and exit ++ ++.SH SEE ALSO ++id3tag(1), id3info(1), id3v2(1) ++.SH AUTHOR ++.B id3lib ++was originally designed and implemented by Dirk Mahoney and is ++maintained by Scott Thomas Haug <sth2@cs.wustl.edu>. Manual page written for ++Debian GNU/Linux by Robert Woodcock <rcw@debian.org>. +--- /dev/null ++++ b/doc/man/id3cp.1 +@@ -0,0 +1,38 @@ ++.TH ID3CP 1 "July 2001" local "User Command" ++.SH NAME ++id3cp \- Copies tags from one file to another. ++.SH SYNOPSIS ++.B id3cp ++.RB [ ++.I OPTION ++.RB ] ... ++.RB [ ++.I SOURCE ++.RB ] ++.RB [ ++.I DEST ++.RB ] ++.br ++.SH DESCRIPTION ++.B Id3cp ++copies tags from SOURCE to DEST. ++.SH OPTIONS ++.TP ++.B \-1, \-\-v1tag ++Render only the id3v1 tag ++.TP ++.B \-2, \-\-v2tag ++Render only the id3v2 tag ++.TP ++.B \-h, \-\-help ++Display help and exit ++.TP ++.B \-v, \-\-version ++Display version information and exit ++.SH SEE ALSO ++id3convert(1), id3info(1), id3v2(1) ++.SH AUTHOR ++.B id3lib ++was originally designed and implemented by Dirk Mahoney and is ++maintained by Scott Thomas Haug <sth2@cs.wustl.edu>. Manual page written for ++Debian GNU/Linux by Robert Woodcock <rcw@debian.org>. diff --git a/source/l/id3lib/patches/id3lib.mkstemp.patch b/source/l/id3lib/patches/id3lib.mkstemp.patch new file mode 100644 index 000000000..36c84179f --- /dev/null +++ b/source/l/id3lib/patches/id3lib.mkstemp.patch @@ -0,0 +1,54 @@ +This patch fixes an issues where temporary files were created in an insecure +way. + +It was first intruduced in version 3.8.3-7 and fixes +http://bugs.debian.org/438540 +--- a/src/tag_file.cpp ++++ b/src/tag_file.cpp +@@ -242,8 +242,8 @@ + strcpy(sTempFile, filename.c_str()); + strcat(sTempFile, sTmpSuffix.c_str()); + +-#if ((defined(__GNUC__) && __GNUC__ >= 3 ) || !defined(HAVE_MKSTEMP)) +- // This section is for Windows folk && gcc 3.x folk ++#if !defined(HAVE_MKSTEMP) ++ // This section is for Windows folk + fstream tmpOut; + createFile(sTempFile, tmpOut); + +@@ -257,7 +257,7 @@ + tmpOut.write((char *)tmpBuffer, nBytes); + } + +-#else //((defined(__GNUC__) && __GNUC__ >= 3 ) || !defined(HAVE_MKSTEMP)) ++#else //!defined(HAVE_MKSTEMP) + + // else we gotta make a temp file, copy the tag into it, copy the + // rest of the old file after the tag, delete the old file, rename +@@ -270,7 +270,7 @@ + //ID3_THROW_DESC(ID3E_NoFile, "couldn't open temp file"); + } + +- ofstream tmpOut(fd); ++ ofstream tmpOut(sTempFile); + if (!tmpOut) + { + tmpOut.close(); +@@ -285,14 +285,14 @@ + uchar tmpBuffer[BUFSIZ]; + while (file) + { +- file.read(tmpBuffer, BUFSIZ); ++ file.read((char *)tmpBuffer, BUFSIZ); + size_t nBytes = file.gcount(); +- tmpOut.write(tmpBuffer, nBytes); ++ tmpOut.write((char *)tmpBuffer, nBytes); + } + + close(fd); //closes the file + +-#endif ////((defined(__GNUC__) && __GNUC__ >= 3 ) || !defined(HAVE_MKSTEMP)) ++#endif ////!defined(HAVE_MKSTEMP) + + tmpOut.close(); + file.close(); diff --git a/source/l/id3lib/patches/id3lib.nullpointer_check.patch b/source/l/id3lib/patches/id3lib.nullpointer_check.patch new file mode 100644 index 000000000..d4ca5d292 --- /dev/null +++ b/source/l/id3lib/patches/id3lib.nullpointer_check.patch @@ -0,0 +1,12 @@ +This patch adds a check for a null pointer +--- a/src/header_tag.cpp ++++ b/src/header_tag.cpp +@@ -54,7 +54,7 @@ + { + size_t bytesUsed = ID3_TagHeader::SIZE; + +- if (_info->is_extended) ++ if (_info && _info->is_extended) + { + bytesUsed += _info->extended_bytes; + } diff --git a/source/l/id3lib/patches/id3lib.utf8_writing.patch b/source/l/id3lib/patches/id3lib.utf8_writing.patch new file mode 100644 index 000000000..3d3f50fed --- /dev/null +++ b/source/l/id3lib/patches/id3lib.utf8_writing.patch @@ -0,0 +1,38 @@ +Patch from 'Spoon' to fix issues with writing certain unicode characters +--- a/ChangeLog ++++ b/ChangeLog +@@ -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 +--- a/src/io_helpers.cpp ++++ b/src/io_helpers.cpp +@@ -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; + } diff --git a/source/l/id3lib/patches/id3lib.vbr_stack_smash.patch b/source/l/id3lib/patches/id3lib.vbr_stack_smash.patch new file mode 100644 index 000000000..9bf33e978 --- /dev/null +++ b/source/l/id3lib/patches/id3lib.vbr_stack_smash.patch @@ -0,0 +1,19 @@ +Description: Fix crashes when reading VBR MP3 file. +Bug-Ubuntu: https://launchpad.net/bugs/444466 +Origin: upstream, http://sourceforge.net/tracker/?func=detail&aid=937707&group_id=979&atid=300979 +Forwarded: yes +Author: Urs Fleisch + +Index: id3lib3.8.3-3.8.3/src/mp3_parse.cpp +=================================================================== +--- id3lib3.8.3-3.8.3.orig/src/mp3_parse.cpp 2009-10-06 23:12:10.381250132 +0200 ++++ id3lib3.8.3-3.8.3/src/mp3_parse.cpp 2009-10-06 23:14:09.545252591 +0200 +@@ -465,7 +465,7 @@ + // from http://www.xingtech.com/developer/mp3/ + + const size_t VBR_HEADER_MIN_SIZE = 8; // "xing" + flags are fixed +- const size_t VBR_HEADER_MAX_SIZE = 116; // frames, bytes, toc and scale are optional ++ const size_t VBR_HEADER_MAX_SIZE = 120; // frames, bytes, toc and scale are optional + + if (mp3size >= vbr_header_offest + VBR_HEADER_MIN_SIZE) + { diff --git a/source/l/id3lib/slack-desc b/source/l/id3lib/slack-desc new file mode 100644 index 000000000..5f6093165 --- /dev/null +++ b/source/l/id3lib/slack-desc @@ -0,0 +1,19 @@ +# HOW TO EDIT THIS FILE: +# The "handy ruler" below makes it easier to edit a package description. Line +# up the first '|' above the ':' following the base package name, and the '|' +# on the right side marks the last column you can put a character in. You must +# make exactly 11 lines for the formatting to be correct. It's also +# customary to leave one space after the ':'. + + |-----handy-ruler------------------------------------------------------| +id3lib: id3lib (ID3 tag manipulation library) +id3lib: +id3lib: This package provides a library for manipulating ID3v1 and ID3v2 tags. +id3lib: Features include identification of valid tags, automatic size +id3lib: conversions, (re)synchronisation of tag frames, seamless tag +id3lib: (de)compression, and optional padding facilities. Additionally, it can +id3lib: display mp3 header info such as bitrate. +id3lib: +id3lib: Homepage: http://id3lib.sourceforge.net/ +id3lib: +id3lib: |