mirror of
https://github.com/love2d/love.git
synced 2026-08-16 00:02:12 +02:00
Potentially fixed a bug in the vorbis decoder seek callback.
This commit is contained in:
@@ -106,10 +106,12 @@ static int vorbisSeek(void *datasource /* ptr to the data that the vorbis files
|
||||
vorbisData->dataRead += (int)actualOffset;
|
||||
break;
|
||||
case SEEK_END: // Seek from the end of the file
|
||||
vorbisData->dataRead = vorbisData->dataSize+1;
|
||||
if (offset < 0)
|
||||
vorbisData->dataRead = vorbisData->dataSize + offset;
|
||||
else
|
||||
vorbisData->dataRead = vorbisData->dataSize;
|
||||
break;
|
||||
default:
|
||||
throw love::Exception("Unknown seek command in vorbisSeek");
|
||||
break;
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user