diff options
Diffstat (limited to 'test/encode/avcenc.c')
-rw-r--r-- | test/encode/avcenc.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/test/encode/avcenc.c b/test/encode/avcenc.c index 74729fb..d5f2bd5 100644 --- a/test/encode/avcenc.c +++ b/test/encode/avcenc.c @@ -953,6 +953,7 @@ bitstream_start(bitstream *bs) { bs->max_size_in_dword = BITSTREAM_ALLOCATE_STEPPING; bs->buffer = calloc(bs->max_size_in_dword * sizeof(int), 1); + assert(bs->buffer); bs->bit_offset = 0; } @@ -990,6 +991,7 @@ bitstream_put_ui(bitstream *bs, unsigned int val, int size_in_bits) if (pos + 1 == bs->max_size_in_dword) { bs->max_size_in_dword += BITSTREAM_ALLOCATE_STEPPING; bs->buffer = realloc(bs->buffer, bs->max_size_in_dword * sizeof(unsigned int)); + assert(bs->buffer); } bs->buffer[pos + 1] = val; |