aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEugene Sandulenko2016-02-23 10:50:42 +0100
committerEugene Sandulenko2016-02-23 11:18:43 +0100
commitea0fb987e042a86b8da683cafa7b9cf04d1636e6 (patch)
tree25b4700251ca78cd751ca44bd244740e6afa607e
parenta2553489a66f6c0ccb937cdaaa643f9f037cf51b (diff)
downloadscummvm-rg350-ea0fb987e042a86b8da683cafa7b9cf04d1636e6.tar.gz
scummvm-rg350-ea0fb987e042a86b8da683cafa7b9cf04d1636e6.tar.bz2
scummvm-rg350-ea0fb987e042a86b8da683cafa7b9cf04d1636e6.zip
WAGE: Fix crashes for poorly initialized objects
-rw-r--r--engines/wage/entities.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/engines/wage/entities.h b/engines/wage/entities.h
index ce006a6785..33cf087322 100644
--- a/engines/wage/entities.h
+++ b/engines/wage/entities.h
@@ -124,7 +124,7 @@ public:
void setDesignBounds(Common::Rect *bounds);
- Common::String toString() { return _name; }
+ Common::String toString() { if (!this) return "<NULL>"; return _name; }
};
class Chr : public Designed {