Commit f7132a7a by andrewlewis Committed by Oliver Woodman

Fix compiler warning about assignment in conditional.

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=140332890
parent f9c7343e
Showing with 2 additions and 2 deletions
...@@ -267,7 +267,7 @@ int decodePacket(AVCodecContext *context, AVPacket *packet, ...@@ -267,7 +267,7 @@ int decodePacket(AVCodecContext *context, AVPacket *packet,
sampleFormat, 1); sampleFormat, 1);
AVAudioResampleContext *resampleContext; AVAudioResampleContext *resampleContext;
if (context->opaque) { if (context->opaque) {
resampleContext = (AVAudioResampleContext *)context->opaque; resampleContext = (AVAudioResampleContext *) context->opaque;
} else { } else {
resampleContext = avresample_alloc_context(); resampleContext = avresample_alloc_context();
av_opt_set_int(resampleContext, "in_channel_layout", channelLayout, 0); av_opt_set_int(resampleContext, "in_channel_layout", channelLayout, 0);
...@@ -326,7 +326,7 @@ void releaseContext(AVCodecContext *context) { ...@@ -326,7 +326,7 @@ void releaseContext(AVCodecContext *context) {
return; return;
} }
AVAudioResampleContext *resampleContext; AVAudioResampleContext *resampleContext;
if (resampleContext = (AVAudioResampleContext *)context->opaque) { if ((resampleContext = (AVAudioResampleContext *) context->opaque)) {
avresample_free(&resampleContext); avresample_free(&resampleContext);
context->opaque = NULL; context->opaque = NULL;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment