From: Inki Dae Date: Mon, 17 Jun 2024 06:38:24 +0000 (+0900) Subject: fix a memory leak bug X-Git-Tag: accepted/tizen/unified/20240903.110722~23 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=1ab9abb59a429a2ef702acf28e513ca6aacf8558;p=platform%2Fcore%2Fapi%2Fsingleo.git fix a memory leak bug Just fix a memory leak bug by releasing singleo service context when the service is destroyed. Change-Id: I8b7856e34d8ff3d171656960d8aa6e6d7c9dac68 Signed-off-by: Inki Dae --- diff --git a/services/singleo_native_capi.cpp b/services/singleo_native_capi.cpp index 6774a0e..3c335aa 100644 --- a/services/singleo_native_capi.cpp +++ b/services/singleo_native_capi.cpp @@ -65,6 +65,8 @@ int singleo_service_destroy(singleo_service_h handle) if (context->_service_type == ServiceType::AUTO_ZOOM) delete static_cast(context->_service_handle); + delete context; + return SINGLEO_ERROR_NONE; }