diff options
author | Monty <xiphmont@xiph.org> | 2003-11-20 06:16:17 +0000 |
---|---|---|
committer | Monty <xiphmont@xiph.org> | 2003-11-20 06:16:17 +0000 |
commit | a2e192fc11e96a947d07e52571f852467f1b9ce6 (patch) | |
tree | e4642f5248f38ad6f84a463484910e69a7eda0a6 | |
parent | 2f293ef4e44ffa6928442eceafe7749ac14503db (diff) | |
download | tremor-a2e192fc11e96a947d07e52571f852467f1b9ce6.tar.gz |
A few last compiler warnings, replace reliance on libc quicksort in floor1.
git-svn-id: https://svn.xiph.org/branches/lowmem-branch/Tremor@5617 0101bb08-14d6-0310-b084-bc0e0c8e3800
-rw-r--r-- | codebook.c | 3 | ||||
-rw-r--r-- | floor1.c | 8 | ||||
-rw-r--r-- | misc.h | 2 | ||||
-rw-r--r-- | res012.c | 8 | ||||
-rw-r--r-- | vorbisfile.c | 5 |
5 files changed, 7 insertions, 19 deletions
@@ -71,6 +71,7 @@ static ogg_uint32_t decpack(long entry,long used_entry,long quantvals, return (ogg_uint32_t)used_entry; } + return 0; /* silence compiler */ } /* 32 bit float (not IEEE; nonnormalized mantissa + @@ -338,7 +339,7 @@ void vorbis_book_clear(codebook *b){ int vorbis_book_unpack(oggpack_buffer *opb,codebook *s){ char *lengthlist=NULL; int quantvals=0; - long i,j,k; + long i,j; int maptype; memset(s,0,sizeof(*s)); @@ -53,9 +53,9 @@ static int ilog(unsigned int v){ return(ret); } -static void mergesort(ogg_uint16_t *index,ogg_uint16_t *vals,ogg_uint16_t n){ +static void mergesort(char *index,ogg_uint16_t *vals,ogg_uint16_t n){ ogg_uint16_t i,j; - ogg_uint16_t *temp,*A=index,*B=_ogg_alloc(0,n*sizeof(*B)); + char *temp,*A=index,*B=_ogg_malloc(n*sizeof(*B)); for(i=1;i<n;i<<=1){ for(j=0;j+i<n;){ @@ -84,10 +84,6 @@ static void mergesort(ogg_uint16_t *index,ogg_uint16_t *vals,ogg_uint16_t n){ } -static int icomp(const void *a,const void *b){ - return(**(ogg_uint16_t **)a-**(ogg_uint16_t **)b); -} - vorbis_info_floor *floor1_info_unpack (vorbis_info *vi,oggpack_buffer *opb){ codec_setup_info *ci=(codec_setup_info *)vi->codec_setup; int j,k,count=0,maxclass=-1,rangebits; @@ -20,7 +20,7 @@ #include "ivorbiscodec.h" #include "os_types.h" -/*#define _VDBG_GRAPHFILE "_0.m"*/ +#define _VDBG_GRAPHFILE "_0.m" #ifdef _VDBG_GRAPHFILE @@ -33,14 +33,6 @@ void res_clear_info(vorbis_info_residue *info){ } } -static int ilog(unsigned int v){ - int ret=0; - while(v){ - ret++; - v>>=1; - } - return(ret); -} /* vorbis_info is for range checking */ int res_unpack(vorbis_info_residue *info, diff --git a/vorbisfile.c b/vorbisfile.c index 31ef4a3..053755e 100644 --- a/vorbisfile.c +++ b/vorbisfile.c @@ -12,7 +12,7 @@ ******************************************************************** function: stdio-based convenience library for opening/seeking/decoding - last mod: $Id: vorbisfile.c,v 1.6.2.4 2003/04/29 04:03:27 xiphmont Exp $ + last mod: $Id: vorbisfile.c,v 1.6.2.5 2003/11/20 06:16:17 xiphmont Exp $ ********************************************************************/ @@ -1476,7 +1476,7 @@ ogg_int64_t ov_pcm_tell(OggVorbis_File *vf){ /* return time offset (milliseconds) of next PCM sample to be read */ ogg_int64_t ov_time_tell(OggVorbis_File *vf){ - int link=0,ret; + int link=0; ogg_int64_t pcm_total=0; ogg_int64_t time_total=0; @@ -1555,7 +1555,6 @@ vorbis_comment *ov_comment(OggVorbis_File *vf,int link){ *section) set to the logical bitstream number */ long ov_read(OggVorbis_File *vf,void *buffer,int bytes_req,int *bitstream){ - int i,j; long samples; long channels; |