View | Details | Raw Unified | Return to bug 169698
Collapse All | Expand All

(-)multimedia/libdvdnav/Makefile (-1 / +6 lines)
Lines 7-12 Link Here
7
7
8
PORTNAME=	libdvdnav
8
PORTNAME=	libdvdnav
9
PORTVERSION=	4.2.0
9
PORTVERSION=	4.2.0
10
PORTREVISION=	1
10
CATEGORIES=	multimedia
11
CATEGORIES=	multimedia
11
# Svn repository URL : svn://svn.mplayerhq.hu/dvdnav/trunk/libdvdnav
12
# Svn repository URL : svn://svn.mplayerhq.hu/dvdnav/trunk/libdvdnav
12
MASTER_SITES=	http://dvdnav.mplayerhq.hu/releases/ \
13
MASTER_SITES=	http://dvdnav.mplayerhq.hu/releases/ \
Lines 29-36 Link Here
29
		--shlibdir="${PREFIX}/lib" \
30
		--shlibdir="${PREFIX}/lib" \
30
		--incdir="${PREFIX}/include/dvdnav" \
31
		--incdir="${PREFIX}/include/dvdnav" \
31
		--disable-opts \
32
		--disable-opts \
32
		--disable-debug \
33
		--cc="${CC}"
33
		--cc="${CC}"
34
.if defined(WITH_DEBUG)
35
CONFIGURE_ARGS+=	--disable-strip
36
.else
37
CONFIGURE_ARGS+=	--disable-debug
38
.endif
34
USE_GMAKE=	yes
39
USE_GMAKE=	yes
35
CONFLICTS=	libdvdnav-mplayer-[0-9]*
40
CONFLICTS=	libdvdnav-mplayer-[0-9]*
36
USE_LDCONFIG=	yes
41
USE_LDCONFIG=	yes
(-)multimedia/libdvdnav/files/patch-src-searching.c (+44 lines)
Line 0 Link Here
1
From 49c67ccf88c688e0e0e9e3b04f651b12c7d7f7f3 Mon Sep 17 00:00:00 2001
2
From: Erik Hovland <erik@hovland.org>
3
Date: Mon, 16 Apr 2012 14:56:43 -0700
4
Subject: [PATCH] Check cell new row before using it to index into
5
 cell_playback
6
7
cellnr is used to index into cell_playback after subtracting
8
one from it. If cellnr is 0, then it will index -1 in cell_playback
9
which will seek out of boundary of cell_playback. This manifested into a
10
segfault for some users as reported by this launchpad bug:
11
https://bugs.launchpad.net/ubuntu/+source/libdvdnav/+bug/934471
12
13
By checking cellnr and skipping the indexing if cellnr is equal to zero
14
then we avoid the segfault. There might be a bigger issue w/ regard to
15
retrieving a value of zero for cell new row, but this fix works for the
16
reporter.
17
18
Thanks goes to Sylvain Henry (hsyl20 AT gmail DOT com for both
19
reporting the bug to launchpad and submitting a potential patch (even
20
though we went w/ a different fix).
21
---
22
 src/searching.c |    6 +++++-
23
 1 file changed, 5 insertions(+), 1 deletion(-)
24
25
diff --git a/src/searching.c b/src/searching.c
26
index 3649e9d..0b5f22a 100644
27
--- src/searching.c
28
+++ src/searching.c
29
@@ -640,7 +640,11 @@ uint32_t dvdnav_describe_title_chapters(dvdnav_t *this, int32_t title, uint64_t
30
       goto fail;
31
     }
32
 
33
-    cellnr = pgc->program_map[ptt[i].pgn-1];
34
+    if ((cellnr = pgc->program_map[ptt[i].pgn-1]) == 0) {
35
+      printerr("Cell new row cannot be 0");
36
+      continue;
37
+    }
38
+
39
     if(ptt[i].pgn < pgc->nr_of_programs)
40
       endcellnr = pgc->program_map[ptt[i].pgn];
41
     else
42
-- 
43
1.7.10.3
44

Return to bug 169698