diff options
author | Adam Michalski <a.michalski2@partner.samsung.com> | 2022-09-13 13:36:41 +0200 |
---|---|---|
committer | Adam Michalski <a.michalski2@partner.samsung.com> | 2022-09-13 13:36:41 +0200 |
commit | 5c657b43b2a551489da7190cb3540bd2a9169c39 (patch) | |
tree | 55a75450b46daa2561afe0fad51c291e84aa53d6 | |
parent | f654a0f0fbac24ced7ff70f1edc98208776dea46 (diff) | |
download | sessiond-5c657b43b2a551489da7190cb3540bd2a9169c39.tar.gz sessiond-5c657b43b2a551489da7190cb3540bd2a9169c39.tar.bz2 sessiond-5c657b43b2a551489da7190cb3540bd2a9169c39.zip |
library: fix a memory leak in the `method_call_sync` routinesubmit/tizen/20220913.195454accepted/tizen/unified/20220915.025944accepted/tizen/unified/20220915.023904accepted/tizen/unified/20220915.015341
Change-Id: I2d4ae28c363996faf859cc33635bc6c777ef2442
-rw-r--r-- | src/library/src/lib.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/library/src/lib.c b/src/library/src/lib.c index b7f846a..94b4459 100644 --- a/src/library/src/lib.c +++ b/src/library/src/lib.c @@ -537,6 +537,8 @@ static int method_call_sync(gchar *method, GVariant *params, const GVariantType if (!retgv || g_err) { LOGE("Error while calling DBus method %s: %s", method, g_dbus_error_get_remote_error(g_err)); + if (retgv) + g_variant_unref(retgv); return gerror_to_errcode(g_err); } |