memleak fix: converter test leak fix
authorMyungJoo Ham <myungjoo.ham@samsung.com>
Wed, 30 Aug 2023 08:29:59 +0000 (17:29 +0900)
committerjaeyun-jung <39614140+jaeyun-jung@users.noreply.github.com>
Wed, 6 Sep 2023 11:20:04 +0000 (20:20 +0900)
converter gtest code mem leak by not calling gst_object_unref

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
tests/nnstreamer_converter/unittest_converter.cc

index e41344e..fe28434 100644 (file)
@@ -439,6 +439,7 @@ TEST (tensorConverterPython, dynamicDimension)
   EXPECT_EQ (1U, config.info.info[0].dimension[3]);
   gst_tensors_config_free (&config);
   gst_caps_unref (caps);
+  gst_object_unref (sink_pad);
 
   EXPECT_EQ (gst_app_src_push_buffer (GST_APP_SRC (appsrc_handle), buf_2), GST_FLOW_OK);
   EXPECT_TRUE (wait_pipeline_process_buffers (data_received, 3, TEST_TIMEOUT_MS));