]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
[mod_portaudio_stream] scan-build: Fix dead assignment. 421/head
authorAndrey Volk <andywolk@gmail.com>
Tue, 25 Feb 2020 20:28:05 +0000 (00:28 +0400)
committerAndrey Volk <andywolk@gmail.com>
Tue, 25 Feb 2020 20:28:05 +0000 (00:28 +0400)
src/mod/formats/mod_portaudio_stream/mod_portaudio_stream.c

index 1d2882ca7470e73257fc726e3b6e2a6c9c7e54d5..e0878a0fe7854bbbf8af01c437ea273c784e9451 100644 (file)
@@ -248,7 +248,7 @@ static void *SWITCH_THREAD_FUNC read_stream_thread(switch_thread_t *thread, void
 {
        portaudio_stream_source_t *source = obj;
        portaudio_stream_context_t *cp;
-       int samples = 0;
+       int samples;
        int bused, bytesToWrite;
 
 
@@ -282,7 +282,6 @@ static void *SWITCH_THREAD_FUNC read_stream_thread(switch_thread_t *thread, void
                                source->ready = 0;
                        } else {
                                while (globals.running && !source->stopped) {
-                                       samples = 0;
                                        switch_mutex_lock(source->device_lock);
                                        samples = ReadAudioStream(source->audio_stream, source->databuf,
                                                                  source->read_codec.implementation->samples_per_packet, 0, &source->timer);