Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.xiph.org/xiph/opus.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMark Harris <mark.hsj@gmail.com>2022-07-07 08:45:41 +0300
committerMark Harris <mark.hsj@gmail.com>2022-07-08 07:39:42 +0300
commitf1b088001ecbc523ffb07109f301d8773bec44b8 (patch)
tree921d61dbd660cbc25a16d170575469e49d0c7388
parent4ad7d2108133d070605b25b1eb91e32c279bf81e (diff)
Fix uninitialized field on custom mode malloc fail
-rw-r--r--celt/modes.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/celt/modes.c b/celt/modes.c
index 390c5e8a..23f7cde6 100644
--- a/celt/modes.c
+++ b/celt/modes.c
@@ -173,7 +173,10 @@ static void compute_allocation_table(CELTMode *mode)
mode->nbAllocVectors = BITALLOC_SIZE;
allocVectors = opus_alloc(sizeof(unsigned char)*(BITALLOC_SIZE*mode->nbEBands));
if (allocVectors==NULL)
+ {
+ mode->allocVectors = NULL;
return;
+ }
/* Check for standard mode */
if (mode->Fs == 400*(opus_int32)mode->shortMdctSize)