diff options
author | Mark Thompson <sw@jkqxz.net> | 2018-02-21 22:03:15 +0000 |
---|---|---|
committer | Mark Thompson <sw@jkqxz.net> | 2018-02-21 22:03:15 +0000 |
commit | af3727e2399df83b57892c22011e4dd748516897 (patch) | |
tree | dffe4406ae9e92408019fa71195e4037453ea8ad /libavcodec | |
parent | 1325ac4c93f27dd56ebce37d8045d7ceb64dc645 (diff) | |
parent | 0e4c166cdd6446522a085dd9731967d09ac71f72 (diff) | |
download | ffmpeg-af3727e2399df83b57892c22011e4dd748516897.tar.gz |
Merge commit '0e4c166cdd6446522a085dd9731967d09ac71f72'
* commit '0e4c166cdd6446522a085dd9731967d09ac71f72':
cbs_h2645: Remove active ps references when it is replaced
Merged-by: Mark Thompson <sw@jkqxz.net>
Diffstat (limited to 'libavcodec')
-rw-r--r-- | libavcodec/cbs_h2645.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/libavcodec/cbs_h2645.c b/libavcodec/cbs_h2645.c index 2f96e4f20e..9864d67acb 100644 --- a/libavcodec/cbs_h2645.c +++ b/libavcodec/cbs_h2645.c @@ -674,6 +674,8 @@ static int cbs_h26 ## h26n ## _replace_ ## ps_var(CodedBitstreamContext *ctx, \ " id : %d.\n", id); \ return AVERROR_INVALIDDATA; \ } \ + if (priv->ps_var[id] == priv->active_ ## ps_var) \ + priv->active_ ## ps_var = NULL ; \ av_freep(&priv->ps_var[id]); \ priv->ps_var[id] = av_malloc(sizeof(*ps_var)); \ if (!priv->ps_var[id]) \ |