Merge branch 'master' into develop_kimkulling

pull/1797/head
Kim Kulling 2018-02-13 20:37:02 +01:00
commit b01795e453
1 changed files with 3 additions and 3 deletions

View File

@ -99,19 +99,19 @@ public:
// Seek specific position
aiReturn Seek(size_t pOffset, aiOrigin pOrigin) {
if (aiOrigin_SET == pOrigin) {
if (pOffset >= length) {
if (pOffset > length) {
return AI_FAILURE;
}
pos = pOffset;
}
else if (aiOrigin_END == pOrigin) {
if (pOffset >= length) {
if (pOffset > length) {
return AI_FAILURE;
}
pos = length-pOffset;
}
else {
if (pOffset+pos >= length) {
if (pOffset+pos > length) {
return AI_FAILURE;
}
pos += pOffset;