openbsd-ports/x11/mplayer/patches/patch-mp3lib_layer2_c
robert 88d299f7f1 - Fix heap overflow in DMO loader. (CVE-2007-1246)
- regen patches while here

pulled from MPlayer SVN by Brad <brad@comstyle.com>
2007-04-13 23:13:21 +00:00

16 lines
542 B
Plaintext

$OpenBSD: patch-mp3lib_layer2_c,v 1.4 2007/04/13 23:13:21 robert Exp $
--- mp3lib/layer2.c.orig Sun Jun 11 20:35:43 2006
+++ mp3lib/layer2.c Sat Apr 14 00:35:29 2007
@@ -294,6 +294,11 @@ static int do_layer2(struct frame *fr,in
fr->jsbound = (fr->mode == MPG_MD_JOINT_STEREO) ?
(fr->mode_ext<<2)+4 : fr->II_sblimit;
+ if (fr->jsbound > fr->II_sblimit) {
+ fprintf(stderr, "Truncating stereo boundary to sideband limit.\n");
+ fr->jsbound=fr->II_sblimit;
+ }
+
if(stereo == 1 || single == 3)
single = 0;