diff options
author | Alexander Akulich <akulichalexander@gmail.com> | 2019-07-06 15:38:31 +0300 |
---|---|---|
committer | Alexander Akulich <akulichalexander@gmail.com> | 2019-07-07 02:39:03 +0300 |
commit | 8d2b3cc9c978b079f74032717532165c65b321cb (patch) | |
tree | 2a880be7564de601b121974dcee43a8313a430b8 | |
parent | 31268fec582776593e54c10c862d9f7af7b3153c (diff) | |
download | telepathy-mission-control-8d2b3cc9c978b079f74032717532165c65b321cb.tar.gz |
McdAccount: Fix memory leak in get_parameter_of_known_type()
Based on a commit by Slava Monich <slava.monich@jolla.com>
-rw-r--r-- | src/mcd-account.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/mcd-account.c b/src/mcd-account.c index e7f5007d..f02c80d2 100644 --- a/src/mcd-account.c +++ b/src/mcd-account.c @@ -450,10 +450,15 @@ mcd_account_get_parameter_of_known_type (McdAccount *account, { memcpy (parameter, &tmp, sizeof (tmp)); } + else + { + g_value_unset (&tmp); + } return TRUE; } + g_value_unset (&tmp); return FALSE; } @@ -3305,6 +3310,7 @@ finally: g_free (new_dir); g_free (contents); g_free (old_file); + g_free (old_dir); } static gboolean |