From 0960e4f6c7b5cd1e00117a67acdebda21b2e95dd Mon Sep 17 00:00:00 2001 From: havoc Date: Tue, 5 Jul 2005 11:57:50 +0000 Subject: [PATCH] stomping more size_t warnings git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5500 d7cf8633-e32d-0410-b094-e92efae38249 --- snd_main.h | 6 +++--- snd_ogg.c | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/snd_main.h b/snd_main.h index d2e37f39..0248a92c 100644 --- a/snd_main.h +++ b/snd_main.h @@ -26,8 +26,8 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. typedef struct { - size_t length; - size_t offset; + unsigned int length; + unsigned int offset; qbyte data[4]; // variable sized } sfxbuffer_t; @@ -59,7 +59,7 @@ struct sfx_s unsigned int flags; // cf SFXFLAG_* defines snd_format_t format; int loopstart; - size_t total_length; + unsigned int total_length; const snd_fetcher_t *fetcher; void *fetcher_data; // Per-sfx data for the sound fetching functions }; diff --git a/snd_ogg.c b/snd_ogg.c index cdc41f75..ee2ecfcf 100644 --- a/snd_ogg.c +++ b/snd_ogg.c @@ -452,7 +452,7 @@ static const sfxbuffer_t* OGG_FetchSound (channel_t* ch, unsigned int start, uns if (sb->offset <= start && sb->offset + sb->length >= start + nbsamples) return sb; - newlength = sb->offset + sb->length - start; + newlength = (int)(sb->offset + sb->length) - start; // If we need to skip some data before decompressing the rest, or if the stream has looped if (newlength < 0 || sb->offset > start) -- 2.39.2