diff options
author | Alexander Akulich <akulichalexander@gmail.com> | 2019-07-06 15:38:31 +0300 |
---|---|---|
committer | Alexander Akulich <akulichalexander@gmail.com> | 2019-07-07 01:40:16 +0300 |
commit | 88ec1e6fe5c12075ee045e9fb7546d198cf9cd08 (patch) | |
tree | 75b71216422df4d406e9cf52f973da7b524fff30 | |
parent | eb49d2e9dada57d7a96892f6d3241d8f5684136e (diff) | |
download | telepathy-mission-control-88ec1e6fe5c12075ee045e9fb7546d198cf9cd08.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 9927f08f..8009110e 100644 --- a/src/mcd-account.c +++ b/src/mcd-account.c @@ -455,10 +455,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; } @@ -3014,6 +3019,7 @@ finally: g_free (new_dir); g_free (contents); g_free (old_file); + g_free (old_dir); } static gboolean |