From 329d8f32349ce401eaf8b486e496b65f27cbd920 Mon Sep 17 00:00:00 2001 From: Darren Salt Date: Fri, 2 Jun 2006 19:54:05 +0000 Subject: Include crc.c directly from xine_decoder.c since that's the only user of the CRC code. Also take the opportunity to make the CRC code static. (Based on a Gentoo patch.) CVS patchset: 8007 CVS date: 2006/06/02 19:54:05 --- src/liba52/a52.h | 1 - src/liba52/crc.c | 4 +--- src/liba52/xine_decoder.c | 4 +++- 3 files changed, 4 insertions(+), 5 deletions(-) (limited to 'src') diff --git a/src/liba52/a52.h b/src/liba52/a52.h index 12883011b..9db52ccf8 100644 --- a/src/liba52/a52.h +++ b/src/liba52/a52.h @@ -58,6 +58,5 @@ void a52_dynrng (a52_state_t * state, sample_t (* call) (sample_t, void *), void * data); int a52_block (a52_state_t * state); void a52_free (a52_state_t * state); -uint16_t crc16_block(uint8_t *data,uint32_t num_bytes); #endif /* A52_H */ diff --git a/src/liba52/crc.c b/src/liba52/crc.c index 2cd92e116..38254c9ef 100644 --- a/src/liba52/crc.c +++ b/src/liba52/crc.c @@ -25,8 +25,6 @@ #include #include -uint16_t crc16_block(uint8_t *,uint32_t); - static const uint16_t crc_lut[256] = { 0x0000,0x8005,0x800f,0x000a,0x801b,0x001e,0x0014,0x8011, @@ -63,7 +61,7 @@ static const uint16_t crc_lut[256] = 0x8213,0x0216,0x021c,0x8219,0x0208,0x820d,0x8207,0x0202 }; -uint16_t crc16_block(uint8_t *data,uint32_t num_bytes) +static uint16_t crc16_block(uint8_t *data,uint32_t num_bytes) { uint32_t i; uint16_t state=0; diff --git a/src/liba52/xine_decoder.c b/src/liba52/xine_decoder.c index 70d5795c1..a8f7219e3 100644 --- a/src/liba52/xine_decoder.c +++ b/src/liba52/xine_decoder.c @@ -17,7 +17,7 @@ * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA * - * $Id: xine_decoder.c,v 1.77 2006/05/03 19:46:07 dsalt Exp $ + * $Id: xine_decoder.c,v 1.78 2006/06/02 19:54:05 dsalt Exp $ * * stuff needed to turn liba52 into a xine decoder plugin */ @@ -64,6 +64,8 @@ #include "buffer.h" #include "xineutils.h" +#include "crc.c" + #undef DEBUG_A52 #ifdef DEBUG_A52 int a52file; -- cgit v1.2.3