diff --git a/cocos/platform/android/CCGLViewImpl-android.cpp b/cocos/platform/android/CCGLViewImpl-android.cpp index 2e218596a9..b9760788b1 100644 --- a/cocos/platform/android/CCGLViewImpl-android.cpp +++ b/cocos/platform/android/CCGLViewImpl-android.cpp @@ -58,7 +58,7 @@ GLViewImpl* GLViewImpl::createWithRect(const std::string& viewName, Rect rect, f ret->autorelease(); return ret; } - + CC_SAFE_DELETE(ret); return nullptr; } @@ -69,7 +69,7 @@ GLViewImpl* GLViewImpl::create(const std::string& viewName) ret->autorelease(); return ret; } - + CC_SAFE_DELETE(ret); return nullptr; } @@ -80,7 +80,7 @@ GLViewImpl* GLViewImpl::createWithFullScreen(const std::string& viewName) ret->autorelease(); return ret; } - + CC_SAFE_DELETE(ret); return nullptr; } diff --git a/cocos/platform/desktop/CCGLViewImpl-desktop.cpp b/cocos/platform/desktop/CCGLViewImpl-desktop.cpp index 0846691299..e25ce56fae 100644 --- a/cocos/platform/desktop/CCGLViewImpl-desktop.cpp +++ b/cocos/platform/desktop/CCGLViewImpl-desktop.cpp @@ -303,7 +303,7 @@ GLViewImpl* GLViewImpl::create(const std::string& viewName) ret->autorelease(); return ret; } - + CC_SAFE_DELETE(ret); return nullptr; } @@ -314,7 +314,7 @@ GLViewImpl* GLViewImpl::createWithRect(const std::string& viewName, Rect rect, f ret->autorelease(); return ret; } - + CC_SAFE_DELETE(ret); return nullptr; } @@ -325,7 +325,7 @@ GLViewImpl* GLViewImpl::createWithFullScreen(const std::string& viewName) ret->autorelease(); return ret; } - + CC_SAFE_DELETE(ret); return nullptr; } @@ -336,7 +336,7 @@ GLViewImpl* GLViewImpl::createWithFullScreen(const std::string& viewName, const ret->autorelease(); return ret; } - + CC_SAFE_DELETE(ret); return nullptr; } diff --git a/cocos/platform/ios/CCGLViewImpl-ios.mm b/cocos/platform/ios/CCGLViewImpl-ios.mm index 44a0faca05..284a3b5a48 100644 --- a/cocos/platform/ios/CCGLViewImpl-ios.mm +++ b/cocos/platform/ios/CCGLViewImpl-ios.mm @@ -46,7 +46,7 @@ GLViewImpl* GLViewImpl::createWithEAGLView(void *eaglview) ret->autorelease(); return ret; } - + CC_SAFE_DELETE(ret); return nullptr; } @@ -57,7 +57,7 @@ GLViewImpl* GLViewImpl::create(const std::string& viewName) ret->autorelease(); return ret; } - + CC_SAFE_DELETE(ret); return nullptr; } @@ -68,7 +68,7 @@ GLViewImpl* GLViewImpl::createWithRect(const std::string& viewName, Rect rect, f ret->autorelease(); return ret; } - + CC_SAFE_DELETE(ret); return nullptr; } @@ -79,7 +79,7 @@ GLViewImpl* GLViewImpl::createWithFullScreen(const std::string& viewName) ret->autorelease(); return ret; } - + CC_SAFE_DELETE(ret); return nullptr; }