Skip to content
Snippets Groups Projects
Commit a3f6e8c4 authored by Michael Niedermayer's avatar Michael Niedermayer
Browse files

avdevice/dshow: Use av_freep() to avoid leaving stale pointers in memory

parent beaea2de
No related branches found
No related tags found
No related merge requests found
...@@ -146,9 +146,9 @@ dshow_read_close(AVFormatContext *s) ...@@ -146,9 +146,9 @@ dshow_read_close(AVFormatContext *s)
IBaseFilter_Release(ctx->device_filter[AudioDevice]); IBaseFilter_Release(ctx->device_filter[AudioDevice]);
if (ctx->device_name[0]) if (ctx->device_name[0])
av_free(ctx->device_name[0]); av_freep(&ctx->device_name[0]);
if (ctx->device_name[1]) if (ctx->device_name[1])
av_free(ctx->device_name[1]); av_freep(&ctx->device_name[1]);
if(ctx->mutex) if(ctx->mutex)
CloseHandle(ctx->mutex); CloseHandle(ctx->mutex);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment