diff options
author | Monty <xiphmont@xiph.org> | 2004-06-17 00:58:19 +0000 |
---|---|---|
committer | Monty <xiphmont@xiph.org> | 2004-06-17 00:58:19 +0000 |
commit | 6a4b552f3033f7cf98e164339412b605091ef4e1 (patch) | |
tree | f35bf28439c107c871f709a9a9038892624c30c6 | |
parent | 5a42681ccc06aa2456eccc42031d371998b4344b (diff) | |
download | ogg-git-6a4b552f3033f7cf98e164339412b605091ef4e1.tar.gz |
Correct masking bug (incorrect implicit cast) in oggpackB_read that's
exposed by 64 bit systems; the 32 bit mask is signed default and being
sign-extended by 64 bit.
svn path=/trunk/ogg/; revision=6832
-rw-r--r-- | src/bitwise.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/bitwise.c b/src/bitwise.c index 719f20c..b1514cc 100644 --- a/src/bitwise.c +++ b/src/bitwise.c @@ -369,7 +369,7 @@ long oggpackB_read(oggpack_buffer *b,int bits){ } } } - ret=((ret&0xffffffff)>>(m>>1))>>((m+1)>>1); + ret=((ret&0xffffffffUL)>>(m>>1))>>((m+1)>>1); overflow: |