Mercurial > libavutil.hg
changeset 317:0df19c6b37d0 libavutil
kill 3 more av_mallocz_static()
author | michael |
---|---|
date | Wed, 14 Mar 2007 01:59:53 +0000 |
parents | 0846319fed73 |
children | a989eb26fcdd |
files | crc.c crc.h |
diffstat | 2 files changed, 14 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/crc.c Tue Mar 13 12:40:13 2007 +0000 +++ b/crc.c Wed Mar 14 01:59:53 2007 +0000 @@ -21,10 +21,17 @@ #include "common.h" #include "crc.h" +#if LIBAVUTIL_VERSION_INT < (50<<16) AVCRC *av_crcEDB88320; AVCRC *av_crc04C11DB7; AVCRC *av_crc8005 ; AVCRC *av_crc07 ; +#else +AVCRC av_crcEDB88320[257]; +AVCRC av_crc04C11DB7[257]; +AVCRC av_crc8005 [257]; +AVCRC av_crc07 [257]; +#endif /** * Inits a crc table.
--- a/crc.h Tue Mar 13 12:40:13 2007 +0000 +++ b/crc.h Wed Mar 14 01:59:53 2007 +0000 @@ -23,10 +23,17 @@ typedef uint32_t AVCRC; +#if LIBAVUTIL_VERSION_INT < (50<<16) extern AVCRC *av_crcEDB88320; extern AVCRC *av_crc04C11DB7; extern AVCRC *av_crc8005 ; extern AVCRC *av_crc07 ; +#else +extern AVCRC av_crcEDB88320[]; +extern AVCRC av_crc04C11DB7[]; +extern AVCRC av_crc8005 []; +extern AVCRC av_crc07 []; +#endif int av_crc_init(AVCRC *ctx, int le, int bits, uint32_t poly, int ctx_size); uint32_t av_crc(const AVCRC *ctx, uint32_t start_crc, const uint8_t *buffer, size_t length);