shithub: opus

Download patch

ref: 149754eab63e0825da5eb4740db2e160bb2105d4
parent: f7bf43b3e9c8586d86fbaa1c16498e6401fdc815
author: Gregory Maxwell <[email protected]>
date: Mon Sep 19 12:40:12 EDT 2011

Patch from Tim to avoid a spurious uninitialized warning in test_opus.c.

--- a/src/test_opus.c
+++ b/src/test_opus.c
@@ -109,7 +109,7 @@
     int skip;
     int stop=0;
     short *in, *out;
-    int application;
+    int application=OPUS_APPLICATION_AUDIO;
     double bits=0.0, bits_act=0.0, bits2=0.0, nrg;
     int bandwidth=-1;
     const char *bandwidth_string;
@@ -150,11 +150,9 @@
     {
        if (strcmp(argv[args], "voip")==0)
           application = OPUS_APPLICATION_VOIP;
-       else if (strcmp(argv[args], "audio")==0)
-          application = OPUS_APPLICATION_AUDIO;
        else if (strcmp(argv[args], "restricted-lowdelay")==0)
           application = OPUS_APPLICATION_RESTRICTED_LOWDELAY;
-       else {
+       else if (strcmp(argv[args], "audio")!=0) {
           fprintf(stderr, "unknown application: %s\n", argv[args]);
           print_usage(argv);
           return 1;