diff options
author | irungentoo <irungentoo@gmail.com> | 2014-11-28 13:10:27 -0500 |
---|---|---|
committer | irungentoo <irungentoo@gmail.com> | 2014-11-28 13:10:27 -0500 |
commit | db68c6eff6adb63acba9e5d3733ec4e395ee87c1 (patch) | |
tree | 4032b993a6814e1302366266fd3322ebe4880b79 /toxav/codec.c | |
parent | 767c0653bd6531c463ee4d005938470462faeb71 (diff) |
Fixed toxav issues.
Diffstat (limited to 'toxav/codec.c')
-rw-r--r-- | toxav/codec.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/toxav/codec.c b/toxav/codec.c index e0b004a4..2849ed69 100644 --- a/toxav/codec.c +++ b/toxav/codec.c | |||
@@ -378,12 +378,13 @@ void cs_do(CSSession *cs) | |||
378 | if (!cs) return; | 378 | if (!cs) return; |
379 | 379 | ||
380 | pthread_mutex_lock(cs->queue_mutex); | 380 | pthread_mutex_lock(cs->queue_mutex); |
381 | /* | 381 | |
382 | if (!cs->active) { | 382 | if (!cs->active) { |
383 | pthread_mutex_unlock(cs->queue_mutex); | 383 | pthread_mutex_unlock(cs->queue_mutex); |
384 | return; | 384 | return; |
385 | } | 385 | } |
386 | 386 | ||
387 | /* | ||
387 | /* Iterate over whole buffers and call playback callback * / | 388 | /* Iterate over whole buffers and call playback callback * / |
388 | if (cs->abuf_ready) while (!DecodedAudioBuffer_empty(cs->abuf_ready)) { | 389 | if (cs->abuf_ready) while (!DecodedAudioBuffer_empty(cs->abuf_ready)) { |
389 | DecodedAudio* p; | 390 | DecodedAudio* p; |
@@ -613,8 +614,6 @@ void cs_kill(CSSession *cs) | |||
613 | 614 | ||
614 | /* Wait threads to close */ | 615 | /* Wait threads to close */ |
615 | pthread_mutex_unlock(cs->queue_mutex); | 616 | pthread_mutex_unlock(cs->queue_mutex); |
616 | pthread_mutex_lock(cs->queue_mutex); | ||
617 | pthread_mutex_unlock(cs->queue_mutex); | ||
618 | 617 | ||
619 | pthread_mutex_destroy(cs->queue_mutex); | 618 | pthread_mutex_destroy(cs->queue_mutex); |
620 | 619 | ||