diff options
author | tma <tma@edf5b092-35ff-0310-97b2-ce42778d08ea> | 2008-03-02 15:28:39 +0000 |
---|---|---|
committer | tma <tma@edf5b092-35ff-0310-97b2-ce42778d08ea> | 2008-03-02 15:28:39 +0000 |
commit | 53bf40f214d5634483240aedaa28a9e54fe518f5 (patch) | |
tree | 044405b524cbcd2ee7f8beb170261689ea711692 /code | |
parent | 9831a9e955d3f1466047c6bf9666b8ad498a2129 (diff) | |
download | ioquake3-aero-53bf40f214d5634483240aedaa28a9e54fe518f5.tar.gz ioquake3-aero-53bf40f214d5634483240aedaa28a9e54fe518f5.zip |
* Ogg codec fix regarding ogg files in pk3s (Tr3b)
git-svn-id: svn://svn.icculus.org/quake3/trunk@1270 edf5b092-35ff-0310-97b2-ce42778d08ea
Diffstat (limited to 'code')
-rw-r--r-- | code/client/snd_codec_ogg.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/code/client/snd_codec_ogg.c b/code/client/snd_codec_ogg.c index 98a5697..a4f1c77 100644 --- a/code/client/snd_codec_ogg.c +++ b/code/client/snd_codec_ogg.c @@ -198,15 +198,19 @@ int S_OGG_Callback_close(void *datasource) // ftell() replacement long S_OGG_Callback_tell(void *datasource) { + snd_stream_t *stream; + // check if input is valid if(!datasource) { - errno = EBADF; + errno = EBADF; return -1; } - // we keep track of the file position in stream->pos - return (long) (((snd_stream_t *) datasource) -> pos); + // snd_stream_t in the generic pointer + stream = (snd_stream_t *) datasource; + + return (long) FS_FTell(stream->file); } // the callback structure |