Fix svace issue 15/151915/2 preview1-00243
authorSeungha Son <seungha.son@samsung.com>
Fri, 22 Sep 2017 09:11:37 +0000 (18:11 +0900)
committerSeungha Son <seungha.son@samsung.com>
Fri, 22 Sep 2017 09:12:14 +0000 (09:12 +0000)
 Value Handle, which is result of method invocation with possible null
 return value, is dereferenced in method call Handle.Dispose()

Change-Id: Ib334114092a9752185ad28d4a38cc989a6c2a162
Signed-off-by: Seungha Son <seungha.son@samsung.com>
src/Tizen.Applications.Notification/Tizen.Applications.Notifications/Notification.cs

index 3064dca..4f0a97a 100755 (executable)
@@ -411,7 +411,7 @@ namespace Tizen.Applications.Notifications
                 return;
             }
 
-            if (disposing)
+            if (disposing && Handle != null && Handle.IsInvalid == false)
             {
                 Handle.Dispose();
             }