summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChris White <chriswhite@gentoo.org>2005-01-30 08:48:29 +0000
committerChris White <chriswhite@gentoo.org>2005-01-30 08:48:29 +0000
commit39a5beaf7ce8c9224756e328dd53712c335b3998 (patch)
tree0c5c69cde0a5ba6a20f50cdf95a8fe566d37575a /media-video
parentRevision bump to add Xft support. bug #78239 (diff)
downloadgentoo-2-39a5beaf7ce8c9224756e328dd53712c335b3998.tar.gz
gentoo-2-39a5beaf7ce8c9224756e328dd53712c335b3998.tar.bz2
gentoo-2-39a5beaf7ce8c9224756e328dd53712c335b3998.zip
Fixed bugs #79243 and 78337.
Diffstat (limited to 'media-video')
-rw-r--r--media-video/mplayer/ChangeLog7
-rw-r--r--media-video/mplayer/files/mplayer-avi_crash.patch51
-rw-r--r--media-video/mplayer/mplayer-1.0_pre5-r5.ebuild5
-rw-r--r--media-video/mplayer/mplayer-1.0_pre6.ebuild5
4 files changed, 63 insertions, 5 deletions
diff --git a/media-video/mplayer/ChangeLog b/media-video/mplayer/ChangeLog
index b53cabfd4487..31d2736b81af 100644
--- a/media-video/mplayer/ChangeLog
+++ b/media-video/mplayer/ChangeLog
@@ -1,6 +1,11 @@
# ChangeLog for media-video/mplayer
# Copyright 2002-2005 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/media-video/mplayer/ChangeLog,v 1.263 2005/01/30 07:33:51 chriswhite Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-video/mplayer/ChangeLog,v 1.264 2005/01/30 08:48:29 chriswhite Exp $
+
+ 30 Jan 2005; Chris White <chriswhite@gentoo.org>
+ +files/mplayer-avi_crash.patch, mplayer-1.0_pre5-r5.ebuild,
+ mplayer-1.0_pre6.ebuild:
+ Fixed bugs #79243 and 78337.
30 Jan 2005; Chris White <chriswhite@gentoo.org>
mplayer-1.0_pre5-r5.ebuild, mplayer-1.0_pre6.ebuild:
diff --git a/media-video/mplayer/files/mplayer-avi_crash.patch b/media-video/mplayer/files/mplayer-avi_crash.patch
new file mode 100644
index 000000000000..e50ae17e0302
--- /dev/null
+++ b/media-video/mplayer/files/mplayer-avi_crash.patch
@@ -0,0 +1,51 @@
+diff -u -r1.63 aviheader.c
+--- libmpdemux/aviheader.c 20 Oct 2004 02:13:33 -0000 1.63
++++ libmpdemux/aviheader.c 29 Dec 2004 13:43:19 -0000
+@@ -44,15 +44,25 @@
+ return 0;
+ }
+
+-/*
++/**
+ * Simple quicksort for AVIINDEXENTRYs
++ * To avoid too deep recursion, the bigger part is handled iteratively,
++ * thus limiting recursion to log2(n) levels.
++ * The pivot element is randomized to "even out" otherwise extreme cases.
+ */
+ static void avi_idx_quicksort(AVIINDEXENTRY *idx, int from, int to)
+ {
+ AVIINDEXENTRY temp;
+- int lo = to;
+- int hi = from;
+- off_t pivot_ofs = AVI_IDX_OFFSET(&idx[(from + to) / 2]);
++ int lo;
++ int hi;
++ off_t pivot_ofs;
++ int pivot_idx;
++ while (from < to) {
++ pivot_idx = from;
++ pivot_idx += rand() % (to - from + 1);
++ pivot_ofs = AVI_IDX_OFFSET(&idx[pivot_idx]);
++ lo = to;
++ hi = from;
+ do {
+ while(pivot_ofs < AVI_IDX_OFFSET(&idx[lo])) lo--;
+ while(pivot_ofs > AVI_IDX_OFFSET(&idx[hi])) hi++;
+@@ -65,8 +75,14 @@
+ lo--; hi++;
+ }
+ } while (lo >= hi);
+- if (from < lo) avi_idx_quicksort(idx, from, lo);
+- if (to > hi) avi_idx_quicksort(idx, hi, to);
++ if ((lo - from) < (to - hi)) {
++ avi_idx_quicksort(idx, from, lo);
++ from = hi;
++ } else {
++ avi_idx_quicksort(idx, hi, to);
++ to = lo;
++ }
++ }
+ }
+
+ void read_avi_header(demuxer_t *demuxer,int index_mode){
+
diff --git a/media-video/mplayer/mplayer-1.0_pre5-r5.ebuild b/media-video/mplayer/mplayer-1.0_pre5-r5.ebuild
index be3e45f62fb0..1eb6161ef1f6 100644
--- a/media-video/mplayer/mplayer-1.0_pre5-r5.ebuild
+++ b/media-video/mplayer/mplayer-1.0_pre5-r5.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/media-video/mplayer/mplayer-1.0_pre5-r5.ebuild,v 1.17 2005/01/30 07:33:51 chriswhite Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-video/mplayer/mplayer-1.0_pre5-r5.ebuild,v 1.18 2005/01/30 08:48:29 chriswhite Exp $
inherit eutils flag-o-matic kernel-mod
@@ -44,8 +44,7 @@ RDEPEND="xvid? ( >=media-libs/xvid-0.9.0 )
>=media-libs/libdv-0.9.5
)
esd? ( media-sound/esound )
- gif? ( media-libs/libungif )
- !gif? ( media-libs/giflib )
+ gif? ( media-libs/giflib )
ggi? ( media-libs/libggi )
gtk? (
media-libs/libpng
diff --git a/media-video/mplayer/mplayer-1.0_pre6.ebuild b/media-video/mplayer/mplayer-1.0_pre6.ebuild
index 1c8a620e0a1d..85c04729a296 100644
--- a/media-video/mplayer/mplayer-1.0_pre6.ebuild
+++ b/media-video/mplayer/mplayer-1.0_pre6.ebuild
@@ -1,6 +1,6 @@
# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/media-video/mplayer/mplayer-1.0_pre6.ebuild,v 1.20 2005/01/30 07:33:51 chriswhite Exp $
+# $Header: /var/cvsroot/gentoo-x86/media-video/mplayer/mplayer-1.0_pre6.ebuild,v 1.21 2005/01/30 08:48:29 chriswhite Exp $
inherit eutils flag-o-matic kernel-mod
@@ -131,6 +131,9 @@ src_unpack() {
# Fix bug #76429
epatch ${FILESDIR}/${PN}-nl.patch
+
+ # fixes bug #78337
+ epatch ${FILESDIR}/${PN}-avi_crash.patch
}
linguas_warn() {