aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/h263.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2007-03-13 22:47:05 +0000
committerMichael Niedermayer <michaelni@gmx.at>2007-03-13 22:47:05 +0000
commit5ac09151792f77c91c5ffe05c9f78928ac303f04 (patch)
treeafc66e88622f74a34adee91dce9aed1b810b1a81 /libavcodec/h263.c
parentca2a0c938e30cadb33e1731965bfac4e9215e121 (diff)
downloadffmpeg-5ac09151792f77c91c5ffe05c9f78928ac303f04.tar.gz
dont malloc() static mv_penalty arrays
Originally committed as revision 8389 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec/h263.c')
-rw-r--r--libavcodec/h263.c5
1 files changed, 1 insertions, 4 deletions
diff --git a/libavcodec/h263.c b/libavcodec/h263.c
index 410c102557..789ece7eac 100644
--- a/libavcodec/h263.c
+++ b/libavcodec/h263.c
@@ -87,7 +87,7 @@ static uint8_t uni_DCtab_chrom_len[512];
static uint16_t uni_DCtab_lum_bits[512];
static uint16_t uni_DCtab_chrom_bits[512];
-static uint8_t (*mv_penalty)[MAX_MV*2+1]= NULL;
+static uint8_t mv_penalty[MAX_FCODE+1][MAX_MV*2+1];
static uint8_t fcode_tab[MAX_MV*2+1];
static uint8_t umv_fcode_tab[MAX_MV*2+1];
@@ -1797,9 +1797,6 @@ static void init_mv_penalty_and_fcode(MpegEncContext *s)
int f_code;
int mv;
- if(mv_penalty==NULL)
- mv_penalty= av_mallocz( sizeof(uint8_t)*(MAX_FCODE+1)*(2*MAX_MV+1) );
-
for(f_code=1; f_code<=MAX_FCODE; f_code++){
for(mv=-MAX_MV; mv<=MAX_MV; mv++){
int len;