On 11/12/2023 12:11 PM, Sebastian Ramacher wrote:
---
libavcodec/avfft.c | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/libavcodec/avfft.c b/libavcodec/avfft.c
index 93203228c2..813b6d61a1 100644
--- a/libavcodec/avfft.c
+++ b/libavcodec/avfft.c
@@ -102,7 +102,8 @@ FFTContext *av_mdct_init(int nbits, int inverse, double
scale)
av_free(s);
return NULL;
}
- }
+ } else
+ s->ctx2 = NULL;
return (FFTContext *)s;
}
@@ -220,7 +221,8 @@ DCTContext *av_dct_init(int nbits, enum DCTTransformType
inverse)
av_free(s);
return NULL;
}
- }
+ } else
+ s->tmp = NULL;
return (DCTContext *)s;
}
IMO just allocate the AVTXWrapper with av_mallocz() instead.
_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
To unsubscribe, visit link above, or email
ffmpeg-devel-requ...@ffmpeg.org with subject "unsubscribe".