From: Paul Wisbey
Date: Tue, 7 Mar 2017 13:22:34 +0000 (+0000)
Subject: Fix to avoid DEREF_AFTER_NULL Svace issue in any.h
X-Git-Tag: dali_1.2.33~4^2
X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F25%2F117825%2F3;p=platform%2Fcore%2Fuifw%2Fdali-core.git
Fix to avoid DEREF_AFTER_NULL Svace issue in any.h
Change-Id: I4e87718579bc208fccf498bc3204b109303abb84
---
diff --git a/dali/public-api/object/any.h b/dali/public-api/object/any.h
index 121d266..f28ed48 100644
--- a/dali/public-api/object/any.h
+++ b/dali/public-api/object/any.h
@@ -176,14 +176,11 @@ public:
template
const Type& Get() const
{
-
if ( NULL == mContainer )
{
AssertAlways( "Any::Get(). mContainer is NULL" );
}
-
- // Check if the value has the same value than the Any type.
- if( mContainer->GetType() != typeid( Type ) )
+ else if( mContainer->GetType() != typeid( Type ) ) // Check if the value has the same value than the Any type.
{
AssertAlways( "Any::Get(). Trying to retrieve a value of a different type than the template one." );
}