summaryrefslogtreecommitdiff
path: root/media-sound
diff options
context:
space:
mode:
authorNick White <git@njw.me.uk>2010-08-02 20:50:31 +0100
committerNick White <git@njw.me.uk>2010-08-02 20:50:31 +0100
commitcfeaa63fc50335db2daab2bcdfaf38a642e5a60c (patch)
treee8089e1227ff97d6d835c2e0451ef22a48888700 /media-sound
parent5f5930586a2d0587a7099b64a37c69c98dd5c2bd (diff)
downloadnjw-gentoo-local-cfeaa63fc50335db2daab2bcdfaf38a642e5a60c.tar.bz2
njw-gentoo-local-cfeaa63fc50335db2daab2bcdfaf38a642e5a60c.zip
Add overflow fix patch to modplugtools
Diffstat (limited to 'media-sound')
-rw-r--r--media-sound/modplugtools/Manifest3
-rw-r--r--media-sound/modplugtools/files/modplug-nooverflow.patch26
-rw-r--r--media-sound/modplugtools/modplugtools-0.5.0.ebuild8
3 files changed, 36 insertions, 1 deletions
diff --git a/media-sound/modplugtools/Manifest b/media-sound/modplugtools/Manifest
index b9cd3e3..43c767e 100644
--- a/media-sound/modplugtools/Manifest
+++ b/media-sound/modplugtools/Manifest
@@ -1,2 +1,3 @@
-EBUILD modplugtools-0.5.0.ebuild 604 RMD160 f587add53e4d7172cde7f27cf0c5142826fb64b8 SHA1 e58f308baf485b8bed40ce9d12c71cef5b554f9f SHA256 16af54906ebc408398381a523a3ca9c8f7dc2a0be249f67ecfcaf7f72e8da5d3
+AUX modplug-nooverflow.patch 1541 RMD160 06c56819142374f42c7e521ba19b0b1342c29e8d SHA1 b5dcfd33cada0b85814f1a3130ca85651b666582 SHA256 909fcf69b4b218667ee06c1cf97a0e3b3a50d47e1ef08e4df4df9ec604fe9c82
+EBUILD modplugtools-0.5.0.ebuild 696 RMD160 36ae040bb466898d58ddae5707d0f905fd32d153 SHA1 4d89412ee4688ad57e725d39174687bee225a274 SHA256 cc917c06848ad02843892374f7e24949e3d2cb258b96ab4862d6c2b264b9ce08
DIST modplugtools-0.5.0.tar.gz 339145 RMD160 7e7f24422f01887fa72165942d7140dd75cd15c7 SHA1 f68dbac4286ec02bc42b130030171186a01a078b SHA256 8a35b29dbac11ac2924358bc16d53a7d7a6c06fd949d3230d6d5d868d473fa99
diff --git a/media-sound/modplugtools/files/modplug-nooverflow.patch b/media-sound/modplugtools/files/modplug-nooverflow.patch
new file mode 100644
index 0000000..2f7d504
--- /dev/null
+++ b/media-sound/modplugtools/files/modplug-nooverflow.patch
@@ -0,0 +1,26 @@
+--- mp123/modplug123.c 2010-04-11 08:29:58.000000000 +0100
++++ mp123/modplug123.c 2010-08-02 20:30:52.739025706 +0100
+@@ -354,8 +354,8 @@ for (song=1; song<argc; song++) {
+
+
+ set_keypress();
+- strcpy(songname, ModPlug_GetName(f2));
+- if (strlen(songname)==0) strcpy(songname,argv[song]);
++ strncpy(songname, ModPlug_GetName(f2), 41);
++ if (strlen(songname)==0) strncpy(songname,argv[song], 41);
+ sprintf(status,"playing %s (%%d.%%d/%d\") (%%d/%%d/%%d%%s) \b\b\b\b",songname,ModPlug_GetLength(f2)/1000,format.rate,format.channels,settings.mBits,order);
+ if (loop) sprintf(status,"looping %s (%%d.%%d/%d\") (%%d/%%d/%%d%%s) \b\b\b\b",songname,ModPlug_GetLength(f2)/1000,format.rate,format.channels,settings.mBits,order);
+
+--- mpplay/modplugplay.c 2010-04-11 09:12:50.000000000 +0100
++++ mpplay/modplugplay.c 2010-08-02 20:30:41.298200678 +0100
+@@ -441,8 +441,8 @@ for (song=1; song<argc; song++) {
+ // [rev--dly--] [sur--dly--] [bas--rng--]
+
+ set_keypress();
+- strcpy(songname, ModPlug_GetName(f2));
+- if (strlen(songname)==0) strcpy(songname,argv[song]);
++ strncpy(songname, ModPlug_GetName(f2), 41);
++ if (strlen(songname)==0) strncpy(songname,argv[song], 41);
+ sprintf(status,"playing %s (%%d.%%d/%d\") (%%d/%%d/%%d%%s) \b\b\b\b",songname,ModPlug_GetLength(f2)/1000,speed,channels,settings.mBits,order);
+ if (loop) sprintf(status,"looping %s (%%d.%%d/%d\") (%%d/%%d/%%d%%s) \b\b\b\b",songname,ModPlug_GetLength(f2)/1000,speed,channels,settings.mBits,order);
+
diff --git a/media-sound/modplugtools/modplugtools-0.5.0.ebuild b/media-sound/modplugtools/modplugtools-0.5.0.ebuild
index db3d16b..8364028 100644
--- a/media-sound/modplugtools/modplugtools-0.5.0.ebuild
+++ b/media-sound/modplugtools/modplugtools-0.5.0.ebuild
@@ -2,6 +2,10 @@
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/media-sound/modplugplay/modplugplay-1.0.ebuild,v 1.8 2009/06/08 21:38:11 jer Exp $
+EAPI="2"
+
+inherit eutils
+
DESCRIPTION="Two players for mod music, modplug123 and modplugplay"
HOMEPAGE="http://modplug-xmms.sourceforge.net/"
SRC_URI="mirror://sourceforge/modplug-xmms/modplug-tools/${P}.tar.gz"
@@ -14,6 +18,10 @@ IUSE=""
RDEPEND=">=media-libs/libmodplug-0.8.8.1"
DEPEND="${RDEPEND}"
+src_prepare() {
+ epatch "${FILESDIR}"/modplug-nooverflow.patch
+}
+
src_install() {
emake DESTDIR="${D}" install || die "emake install failed"
}