From 7bf62e8da66ca8ff0acc2702f92ea4fe06eb94b1 Mon Sep 17 00:00:00 2001 From: Dan Everton Date: Sat, 10 Feb 2007 11:44:26 +0000 Subject: * Sync Speex codec with Speex SVN revision 12449 (roughly Speex 1.2beta1). * Redo the changes required to make Speex compile in Rockbox. Should be a bit easier to keep in sync with Speex SVN now. * Fix name of Speex library in codecs Makefile. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12254 a1c6a512-1295-4272-9138-f99709370657 --- apps/codecs/libspeex/bits.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'apps/codecs/libspeex/bits.c') diff --git a/apps/codecs/libspeex/bits.c b/apps/codecs/libspeex/bits.c index 376e804..6ea495f 100644 --- a/apps/codecs/libspeex/bits.c +++ b/apps/codecs/libspeex/bits.c @@ -76,6 +76,7 @@ void speex_bits_destroy(SpeexBits *bits) void speex_bits_reset(SpeexBits *bits) { + /* We only need to clear the first byte now */ bits->chars[0]=0; bits->nbBits=0; bits->charPtr=0; @@ -225,11 +226,10 @@ void speex_bits_pack(SpeexBits *bits, int data, int nbBits) speex_warning("Buffer too small to pack bits"); if (bits->owner) { - int new_nchars = ((bits->buf_size+5)*3)>>1; + int new_nchars = ((bits->buf_size+5)*3)>>1; char *tmp = (char*)speex_realloc(bits->chars, new_nchars); if (tmp) { - speex_memset_bytes(tmp, 0, new_nchars); bits->buf_size=new_nchars; bits->chars=tmp; } else { -- cgit v1.1