shithub: opus

Download patch

ref: 837583067a777dc095d0bf46aa908c93321d8eae
parent: 8fe210f14b040880829682a9f3f90b02993b4a64
author: Jean-Marc Valin <[email protected]>
date: Fri Dec 16 09:11:48 EST 2016

Adding a missing "else"

Thanks to Zhendong Wu for spotting the issue

--- a/src/opus_encoder.c
+++ b/src/opus_encoder.c
@@ -1552,7 +1552,7 @@
        {
          if (frame_size == 2*st->Fs/25)  /* 80 ms -> 2x 40 ms */
            enc_frame_size = st->Fs/25;
-         if (frame_size == 3*st->Fs/25)  /* 120 ms -> 2x 60 ms */
+         else if (frame_size == 3*st->Fs/25)  /* 120 ms -> 2x 60 ms */
            enc_frame_size = 3*st->Fs/50;
          else                            /* 100 ms -> 5x 20 ms */
            enc_frame_size = st->Fs/50;