summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDiego 'Flameeyes' Pettenò <flameeyes@gmail.com>2007-12-11 22:41:15 +0100
committerDiego 'Flameeyes' Pettenò <flameeyes@gmail.com>2007-12-11 22:41:15 +0100
commit33e998789adf58391439dfbc9f6e67c8451b8c74 (patch)
treed9deac7487ded3d6035119fbc01941492f9569ba /src
parent47b3936175fa3e8eaff2401301b31f149083e222 (diff)
downloadxine-lib-33e998789adf58391439dfbc9f6e67c8451b8c74.tar.gz
xine-lib-33e998789adf58391439dfbc9f6e67c8451b8c74.tar.bz2
Actually use the context already allocated by libavutil.
Diffstat (limited to 'src')
-rw-r--r--src/input/input_dvb.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/input/input_dvb.c b/src/input/input_dvb.c
index 628c38c28..c8b0eb5fe 100644
--- a/src/input/input_dvb.c
+++ b/src/input/input_dvb.c
@@ -2448,9 +2448,8 @@ static void ts_rewrite_packets (dvb_input_plugin_t *this, unsigned char * origin
originalPkt+=data_offset;
if (pid == 0 && sync_byte==0x47) {
- static AVCRC crc_ctx; static int ctx_init = 0;
- if ( ! ctx_init )
- ctx_init = !av_crc_init(&crc_ctx, 0, 32, AV_CRC_32_IEEE, sizeof(AVCRC)*257);
+ if ( ! *av_crc04C11DB7 )
+ av_crc_init(av_crc04C11DB7, 0, 32, AV_CRC_32_IEEE, sizeof(AVCRC)*257);
unsigned long crc;
@@ -2463,7 +2462,7 @@ static void ts_rewrite_packets (dvb_input_plugin_t *this, unsigned char * origin
originalPkt[11]=(this->channels[this->channel].pmtpid >> 8) & 0xff;
originalPkt[12]=this->channels[this->channel].pmtpid & 0xff;
- crc = av_crc(&crc_ctx, 0xffffffff, originalPkt+1, 12);
+ crc = av_crc(av_crc04C11DB7, 0xffffffff, originalPkt+1, 12);
originalPkt[13]=(crc>>24) & 0xff;
originalPkt[14]=(crc>>16) & 0xff;