[xiph-cvs] cvs commit: vorbis-tools/oggenc oggenc.c

Michael Smith msmith at xiph.org
Thu Nov 7 02:37:02 PST 2002



msmith      02/11/07 05:37:01

  Modified:    oggenc   oggenc.c
  Log:
  Fix a minor bug that caused crashes if --resample was used to 'resample' to the
  same rate as the input.

Revision  Changes    Path
1.69      +2 -2      vorbis-tools/oggenc/oggenc.c

Index: oggenc.c
===================================================================
RCS file: /usr/local/cvsroot/vorbis-tools/oggenc/oggenc.c,v
retrieving revision 1.68
retrieving revision 1.69
diff -u -r1.68 -r1.69
--- oggenc.c	7 Nov 2002 10:18:32 -0000	1.68
+++ oggenc.c	7 Nov 2002 10:37:01 -0000	1.69
@@ -318,7 +318,7 @@
             else {
                 fprintf(stderr, _("ERROR: Can't downmix except from stereo to mono\n"));
                 errors++;
-                if(opt.resamplefreq)
+                if(opt.resamplefreq && opt.resamplefreq != enc_opts.rate)
                     clear_resample(&enc_opts);
                 goto clear_all;
             }
@@ -348,7 +348,7 @@
             clear_scaler(&enc_opts);
         if(opt.downmix)
             clear_downmix(&enc_opts);
-        if(opt.resamplefreq)
+        if(opt.resamplefreq && opt.resamplefreq != enc_opts.rate)
             clear_resample(&enc_opts);
 clear_all:
 

<p><p>--- >8 ----
List archives:  http://www.xiph.org/archives/
Ogg project homepage: http://www.xiph.org/ogg/
To unsubscribe from this list, send a message to 'cvs-request at xiph.org'
containing only the word 'unsubscribe' in the body.  No subject is needed.
Unsubscribe messages sent to the list will be ignored/filtered.



More information about the commits mailing list