Commit bfbffbd7 authored by rogerdpack's avatar rogerdpack Committed by Michael Niedermayer

dshow: avoid duplicate NULL check before free

Signed-off-by: 's avatarrogerdpack <rogerpack2005@gmail.com>
Signed-off-by: 's avatarMichael Niedermayer <michael@niedermayer.cc>
parent 9e907c04
......@@ -104,14 +104,10 @@ dshow_read_close(AVFormatContext *s)
if (ctx->device_filter[AudioDevice])
IBaseFilter_Release(ctx->device_filter[AudioDevice]);
if (ctx->device_name[0])
av_freep(&ctx->device_name[0]);
if (ctx->device_name[1])
av_freep(&ctx->device_name[1]);
if (ctx->device_unique_name[0])
av_freep(&ctx->device_unique_name[0]);
if (ctx->device_unique_name[1])
av_freep(&ctx->device_unique_name[1]);
av_freep(&ctx->device_name[0]);
av_freep(&ctx->device_name[1]);
av_freep(&ctx->device_unique_name[0]);
av_freep(&ctx->device_unique_name[1]);
if(ctx->mutex)
CloseHandle(ctx->mutex);
......
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 to comment