wok-6.x view gst-plugins-base/stuff/oggstream-fix-crashes-with-0-byte-vorbis-packets.patch @ rev 11854
locale*: update WANTED
author | Pascal Bellard <pascal.bellard@slitaz.org> |
---|---|
date | Mon Feb 27 11:20:24 2012 +0100 (2012-02-27) |
parents | |
children |
line source
1 From 8bd3bdaf3768b3fb6adc85b3bc681fdce07b786e Mon Sep 17 00:00:00 2001
2 From: Jonathan Liu <net147@gmail.com>
3 Date: Wed, 03 Aug 2011 08:18:29 +0000
4 Subject: oggstream: Fix crashes with 0-byte vorbis packets
6 Fixes bug #655574.
7 ---
8 diff --git a/ext/ogg/gstoggstream.c b/ext/ogg/gstoggstream.c
9 index e843f48..77f39d4 100644
10 --- a/ext/ogg/gstoggstream.c
11 +++ b/ext/ogg/gstoggstream.c
12 @@ -792,7 +792,7 @@ packet_duration_vorbis (GstOggStream * pad, ogg_packet * packet)
13 int size;
14 int duration;
16 - if (packet->packet[0] & 1)
17 + if (packet->bytes == 0 || packet->packet[0] & 1)
18 return 0;
20 mode = (packet->packet[0] >> 1) & ((1 << pad->vorbis_log2_num_modes) - 1);
21 --
22 cgit v0.8.3-6-g21f6