Message ID | AS8P250MB07445A8B4E600CB9528F1E058F512@AS8P250MB0744.EURP250.PROD.OUTLOOK.COM |
---|---|
State | Accepted |
Commit | e7c33c92d1eb04669553a89f8e69c64d4d77d9f4 |
Headers | show |
Series | [FFmpeg-devel,1/5] avformat/iamf_writer: Don't leak on error when adding ParamDefinition | expand |
Context | Check | Description |
---|---|---|
yinshiyou/make_loongarch64 | success | Make finished |
yinshiyou/make_fate_loongarch64 | success | Make fate finished |
andriy/configure_x86 | warning | Failed to apply patch |
On 2/19/2024 6:52 PM, Andreas Rheinhardt wrote: > This has been allocated via av_calloc() a few lines above. > > Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com> > --- > libavformat/iamf_writer.c | 1 - > 1 file changed, 1 deletion(-) > > diff --git a/libavformat/iamf_writer.c b/libavformat/iamf_writer.c > index e0c47b5e9d..9a665dc002 100644 > --- a/libavformat/iamf_writer.c > +++ b/libavformat/iamf_writer.c > @@ -251,7 +251,6 @@ int ff_iamf_add_audio_element(IAMFContext *iamf, const AVStreamGroup *stg, void > int nb_channels = iamf_audio_element->layers[i]->ch_layout.nb_channels; > > IAMFLayer *layer = &audio_element->layers[i]; > - memset(layer, 0, sizeof(*layer)); > > if (i) > nb_channels -= iamf_audio_element->layers[i - 1]->ch_layout.nb_channels; LGTM
diff --git a/libavformat/iamf_writer.c b/libavformat/iamf_writer.c index e0c47b5e9d..9a665dc002 100644 --- a/libavformat/iamf_writer.c +++ b/libavformat/iamf_writer.c @@ -251,7 +251,6 @@ int ff_iamf_add_audio_element(IAMFContext *iamf, const AVStreamGroup *stg, void int nb_channels = iamf_audio_element->layers[i]->ch_layout.nb_channels; IAMFLayer *layer = &audio_element->layers[i]; - memset(layer, 0, sizeof(*layer)); if (i) nb_channels -= iamf_audio_element->layers[i - 1]->ch_layout.nb_channels;
This has been allocated via av_calloc() a few lines above. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com> --- libavformat/iamf_writer.c | 1 - 1 file changed, 1 deletion(-)