- upstream patch fixing crash of oggenc --resample (#526653)

This commit is contained in:
Kamil Dudka 2009-10-06 19:31:07 +00:00
parent 54643fe7a4
commit 8790921c99
2 changed files with 36 additions and 2 deletions

View File

@ -0,0 +1,29 @@
diff -rup vorbis-tools-1.2.0.orig/oggenc/oggenc.c vorbis-tools-1.2.0/oggenc/oggenc.c
--- vorbis-tools-1.2.0.orig/oggenc/oggenc.c 2008-03-03 06:37:27.000000000 +0100
+++ vorbis-tools-1.2.0/oggenc/oggenc.c 2009-10-06 21:27:09.398047466 +0200
@@ -147,6 +147,7 @@ int main(int argc, char **argv)
char *artist=NULL, *album=NULL, *title=NULL, *track=NULL;
char *date=NULL, *genre=NULL;
input_format *format;
+ int resampled = 0;
/* Set various encoding defaults */
@@ -324,6 +325,8 @@ int main(int argc, char **argv)
if(opt.resamplefreq && opt.resamplefreq != enc_opts.rate) {
int fromrate = enc_opts.rate;
+
+ resampled = 1;
enc_opts.resamplefreq = opt.resamplefreq;
if(setup_resample(&enc_opts)) {
errors++;
@@ -369,7 +372,7 @@ int main(int argc, char **argv)
clear_scaler(&enc_opts);
if(opt.downmix)
clear_downmix(&enc_opts);
- if(opt.resamplefreq && opt.resamplefreq != enc_opts.rate)
+ if(resampled)
clear_resample(&enc_opts);
clear_all:

View File

@ -1,13 +1,14 @@
Summary: The Vorbis General Audio Compression Codec tools
Name: vorbis-tools
Version: 1.2.0
Release: 5%{?dist}
Release: 6%{?dist}
Epoch: 1
Group: Applications/Multimedia
License: GPLv2
URL: http://www.xiph.org/
Source: http://www.xiph.org/ogg/vorbis/download/%{name}-%{version}.tar.gz
Patch0: vorbis-tools-1.2.0-non-block.patch
Patch1: vorbis-tools-1.2.0-oggenc-resample.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires: libvorbis-devel libao-devel curl-devel speex-devel flac-devel
Obsoletes: vorbis < %{epoch}:%{version}-%{release}
@ -24,7 +25,8 @@ comment editor.
%prep
%setup -q
%patch0 -p1 -b .non-block
%patch0 -p1
%patch1 -p1
%build
%configure
@ -49,6 +51,9 @@ rm -rf $RPM_BUILD_ROOT
%changelog
* Tue Oct 06 2009 Kamil Dudka <kdudka@redhat.com> - 1:1.2.0-6
- upstream patch fixing crash of oggenc --resample (#526653)
* Sun Jul 26 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1:1.2.0-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild