Fix RESOURCE_LEAK issue 34/240134/1
authorJusung Son <jusung07.son@samsung.com>
Tue, 4 Aug 2020 01:10:30 +0000 (10:10 +0900)
committerJusung Son <jusung07.son@samsung.com>
Tue, 4 Aug 2020 01:10:30 +0000 (10:10 +0900)
Change-Id: I094cbae845857eb8420292cc43bc3b053a78a9fc
Signed-off-by: Jusung Son <jusung07.son@samsung.com>
unittest/src/test-watchface-complication-provider.cc

index 94fd3dd..0e25687 100644 (file)
@@ -695,6 +695,8 @@ TEST_F(CWCP, watchface_complication_provider_event_get_context)
   bundle_free(touch_data);
   bundle_free(shared);
   bundle_free(context);
+  if (ret == WATCHFACE_COMPLICATION_ERROR_NONE)
+    bundle_free(ret_context);
   EXPECT_EQ(WATCHFACE_COMPLICATION_ERROR_NONE, ret);
 
   ret = watchface_complication_provider_event_get_context(