aboutsummaryrefslogtreecommitdiff
path: root/engines/gob
diff options
context:
space:
mode:
Diffstat (limited to 'engines/gob')
-rw-r--r--engines/gob/videoplayer.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/engines/gob/videoplayer.cpp b/engines/gob/videoplayer.cpp
index fe034304e1..6230cad18c 100644
--- a/engines/gob/videoplayer.cpp
+++ b/engines/gob/videoplayer.cpp
@@ -168,7 +168,7 @@ VideoPlayer::~VideoPlayer() {
bool VideoPlayer::findFile(char *fileName, Type &which) {
char *extStart = strrchr(fileName, '.');
// There's no empty extension, Or the filename with its current extension is not found
- if ((extStart == (fileName + strlen(fileName) - 1)) || (!_vm->_dataIO->existData(fileName))) {
+ if ((extStart) && ((extStart == (fileName + strlen(fileName) - 1)) || (!_vm->_dataIO->existData(fileName)))) {
*extStart = 0;
extStart = 0;
}