summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMonty <xiphmont@xiph.org>2003-04-09 09:43:49 +0000
committerMonty <xiphmont@xiph.org>2003-04-09 09:43:49 +0000
commit7916a80caf5ce632a1aacd9418b76b719c3fb772 (patch)
tree6f25c547256157e374359472b5c8862c275976cc
parentde7e6239b129cb23325b9e826282588cbaa4c650 (diff)
downloadtremor-7916a80caf5ce632a1aacd9418b76b719c3fb772.tar.gz
Rather than dealing with autoconf (which can't do cross-compile tests
anyway), throw OV_EIMPL on architectures where right shift of a signed int is not arithmetic. Monty git-svn-id: https://svn.xiph.org/branches/lowmem-branch/Tremor@4598 0101bb08-14d6-0310-b084-bc0e0c8e3800
-rw-r--r--misc.h2
-rw-r--r--synthesis.c4
-rw-r--r--vorbisfile.c7
3 files changed, 9 insertions, 4 deletions
diff --git a/misc.h b/misc.h
index 715894e..32ecc0a 100644
--- a/misc.h
+++ b/misc.h
@@ -20,7 +20,7 @@
#include "ivorbiscodec.h"
#include "os_types.h"
-#define _VDBG_GRAPHFILE "_0.m"
+//#define _VDBG_GRAPHFILE "_0.m"
#ifdef _VDBG_GRAPHFILE
diff --git a/synthesis.c b/synthesis.c
index 3006eee..5b04cb5 100644
--- a/synthesis.c
+++ b/synthesis.c
@@ -12,7 +12,7 @@
********************************************************************
function: single-block PCM synthesis
- last mod: $Id: synthesis.c,v 1.4 2003/03/29 03:07:21 xiphmont Exp $
+ last mod: $Id: synthesis.c,v 1.4.2.1 2003/04/09 09:43:49 xiphmont Exp $
********************************************************************/
@@ -78,7 +78,7 @@ int vorbis_synthesis(vorbis_block *vb,ogg_packet *op,int decodep){
vb->pcmend=0;
vb->pcm=NULL;
- return(0);
+ return 0;
}
}
diff --git a/vorbisfile.c b/vorbisfile.c
index 41239d3..76afad5 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 2003/03/30 23:40:56 xiphmont Exp $
+ last mod: $Id: vorbisfile.c,v 1.6.2.1 2003/04/09 09:43:49 xiphmont Exp $
********************************************************************/
@@ -668,6 +668,11 @@ static int _ov_open1(void *f,OggVorbis_File *vf,char *initial,
int ret;
memset(vf,0,sizeof(*vf));
+
+ /* Tremor assumes in multiple places that right shift of a signed
+ integer is an arithmetic shift */
+ if( (-1>>1) != -1) return OV_EIMPL;
+
vf->datasource=f;
vf->callbacks = callbacks;