Merge commit '11f024ef0ab923ed8680fc35a087d576e549c849'
authorMichael Niedermayer <michaelni@gmx.at>
Wed, 29 Apr 2015 11:24:18 +0000 (13:24 +0200)
committerMichael Niedermayer <michaelni@gmx.at>
Wed, 29 Apr 2015 11:26:33 +0000 (13:26 +0200)
* commit '11f024ef0ab923ed8680fc35a087d576e549c849':
  h264: move freeing the escaped RBSP buffer to free_context()

Merged-by: Michael Niedermayer <michaelni@gmx.at>
1  2 
libavcodec/h264.c
libavcodec/h264.h
libavcodec/h264_slice.c

Simple merge
@@@ -1184,8 -1084,6 +1184,8 @@@ int ff_h264_update_thread_context(AVCod
  
  void ff_h264_flush_change(H264Context *h);
  
- void ff_h264_free_tables(H264Context *h, int free_rbsp);
+ void ff_h264_free_tables(H264Context *h);
  
 +void ff_h264_set_erpic(ERPicture *dst, H264Picture *src);
 +
  #endif /* AVCODEC_H264_H */
@@@ -1169,21 -1059,6 +1169,21 @@@ static int h264_slice_header_init(H264C
      h->context_initialized = 1;
  
      return 0;
-     ff_h264_free_tables(h, 0);
 +fail:
++    ff_h264_free_tables(h);
 +    h->context_initialized = 0;
 +    return ret;
 +}
 +
 +static enum AVPixelFormat non_j_pixfmt(enum AVPixelFormat a)
 +{
 +    switch (a) {
 +    case AV_PIX_FMT_YUVJ420P: return AV_PIX_FMT_YUV420P;
 +    case AV_PIX_FMT_YUVJ422P: return AV_PIX_FMT_YUV422P;
 +    case AV_PIX_FMT_YUVJ444P: return AV_PIX_FMT_YUV444P;
 +    default:
 +        return a;
 +    }
  }
  
  /**