aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--engines/gob/driver_vga.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/engines/gob/driver_vga.cpp b/engines/gob/driver_vga.cpp
index c93962c206..7be1daf9f3 100644
--- a/engines/gob/driver_vga.cpp
+++ b/engines/gob/driver_vga.cpp
@@ -75,6 +75,16 @@ void VGAVideoDriver::drawLetter(unsigned char item, int16 x, int16 y,
uint16 data;
const byte *src = font.getCharData(item);
+
+ // This happens for me at the mountain (World 6) in Gobliins 2, if I
+ // move the cursor over the "!" part of the ledge while trying to use
+ // an object.
+
+ if (!src) {
+ warning("drawLetter: getCharData() returned NULL");
+ return;
+ }
+
byte *dst = dest.getVidMem() + x + dest.getWidth() * y;
int nWidth = font.getCharWidth();