Showing the changes to libavcodec (1 of 1 file). Show all
Unified · Split
| @@ -133,14 +133,12 @@ static int h264_set_extradata(AVCodecContext *avctx, FFAMediaFormat *format) · 132 unmodified lines | ||
| 133 | 133 | int i; |
| 134 | 134 | int ret; |
| 135 | 135 | |
| 136 | − H264ParamSets ps; | |
| 136 | + H264ParamSets ps = {0}; | |
| 137 | 137 | const PPS *pps = NULL; |
| 138 | 138 | const SPS *sps = NULL; |
| 139 | 139 | int is_avc = 0; |
| 140 | 140 | int nal_length_size = 0; |
| 141 | 141 | |
| 142 | − memset(&ps, 0, sizeof(ps)); | |
| 143 | − | |
| 144 | 142 | ret = ff_h264_decode_extradata(avctx->extradata, avctx->extradata_size, |
| 145 | 143 | &ps, &is_avc, &nal_length_size, 0, avctx); |
| 146 | 144 | if (ret < 0) { |
| @@ -199,8 +197,8 @@ static int hevc_set_extradata(AVCodecContext *avctx, FFAMediaFormat *format) · 52 unmodified lines | ||
| 199 | 197 | int i; |
| 200 | 198 | int ret; |
| 201 | 199 | |
| 202 | − HEVCParamSets ps; | |
| 203 | − HEVCSEI sei; | |
| 200 | + HEVCParamSets ps = {0}; | |
| 201 | + HEVCSEI sei = {0}; | |
| 204 | 202 | |
| 205 | 203 | const HEVCVPS *vps = NULL; |
| 206 | 204 | const HEVCPPS *pps = NULL; |
| @@ -215,9 +213,6 @@ static int hevc_set_extradata(AVCodecContext *avctx, FFAMediaFormat *format) · 8 unmodified lines | ||
| 215 | 213 | int sps_data_size = 0; |
| 216 | 214 | int pps_data_size = 0; |
| 217 | 215 | |
| 218 | − memset(&ps, 0, sizeof(ps)); | |
| 219 | − memset(&sei, 0, sizeof(sei)); | |
| 220 | − | |
| 221 | 216 | ret = ff_hevc_decode_extradata(avctx->extradata, avctx->extradata_size, |
| 222 | 217 | &ps, &sei, &is_nalff, &nal_length_size, 0, 1, avctx); |
| 223 | 218 | if (ret < 0) { |