Browse Source

avformat/sierravmd: use av_freep() for freeing context fields

This ensures that there are no stale pointers

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
tags/n2.1
Michael Niedermayer 11 years ago
parent
commit
02f56bfcc3
1 changed files with 3 additions and 3 deletions
  1. +3
    -3
      libavformat/sierravmd.c

+ 3
- 3
libavformat/sierravmd.c View File

@@ -252,8 +252,8 @@ static int vmd_read_header(AVFormatContext *s)
return 0;

error:
av_free(raw_frame_table);
av_free(vmd->frame_table);
av_freep(&raw_frame_table);
av_freep(&vmd->frame_table);
return ret;
}

@@ -304,7 +304,7 @@ static int vmd_read_close(AVFormatContext *s)
{
VmdDemuxContext *vmd = s->priv_data;

av_free(vmd->frame_table);
av_freep(&vmd->frame_table);

return 0;
}


Loading…
Cancel
Save