aboutsummaryrefslogtreecommitdiff
path: root/graphics/surface.h
diff options
context:
space:
mode:
authorMartin Kiewitz2013-12-04 20:42:50 +0100
committerMartin Kiewitz2013-12-04 20:42:50 +0100
commiteaf6367bb26b95af7e27ebbbb090664a3ad04e65 (patch)
treef4acee388f2591f0cfa0848aa337f9cca5733c0d /graphics/surface.h
parent8bdffcb2fb7aefc96aa10fde1bebd372233cac9d (diff)
parent203f562d375ac5c7cc665c8feac4020f8de2a5ff (diff)
downloadscummvm-rg350-eaf6367bb26b95af7e27ebbbb090664a3ad04e65.tar.gz
scummvm-rg350-eaf6367bb26b95af7e27ebbbb090664a3ad04e65.tar.bz2
scummvm-rg350-eaf6367bb26b95af7e27ebbbb090664a3ad04e65.zip
Merge branch 'master' of github.com:scummvm/scummvm
Diffstat (limited to 'graphics/surface.h')
-rw-r--r--graphics/surface.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/graphics/surface.h b/graphics/surface.h
index 07e289b0bb..f1b2aa64ab 100644
--- a/graphics/surface.h
+++ b/graphics/surface.h
@@ -334,7 +334,9 @@ public:
*/
struct SharedPtrSurfaceDeleter {
void operator()(Surface *ptr) {
- ptr->free();
+ if (ptr) {
+ ptr->free();
+ }
delete ptr;
}
};