Browse Source

cmdutils: use sws_freeContext() instead of av_freep().

av_freep(swsContext) will leak all memory potentially
allocated within the swsContext.
tags/n0.8
Ronald S. Bultje 14 years ago
parent
commit
faf8d3ddfa
1 changed files with 2 additions and 1 deletions
  1. +2
    -1
      cmdutils.c

+ 2
- 1
cmdutils.c View File

@@ -76,7 +76,8 @@ void uninit_opts(void)
av_freep(&avformat_opts->key); av_freep(&avformat_opts->key);
av_freep(&avformat_opts); av_freep(&avformat_opts);
#if CONFIG_SWSCALE #if CONFIG_SWSCALE
av_freep(&sws_opts);
sws_freeContext(sws_opts);
sws_opts = NULL;
#endif #endif
for (i = 0; i < opt_name_count; i++) { for (i = 0; i < opt_name_count; i++) {
//opt_values are only stored for codec-specific options in which case //opt_values are only stored for codec-specific options in which case


Loading…
Cancel
Save