aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChris Michael <cp.michael@samsung.com>2016-12-19 14:49:36 (GMT)
committerChris Michael <cp.michael@samsung.com>2016-12-19 14:49:36 (GMT)
commitd0a626351946cc7eee7c0c9da1d142e763097153 (patch)
treefbabf8c1ef1bb0a71f9dec5e7f4c1bc73bd96b38
parentelput: Fix resource leak (diff)
downloadefl-d0a626351946cc7eee7c0c9da1d142e763097153.tar.gz
elput: Fix resource leak
Coverty reports that we leak 'reply' here if we fall into the error condition. CID1367506 @fix Signed-off-by: Chris Michael <cp.michael@samsung.com>
-rw-r--r--src/lib/elput/elput_logind.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/lib/elput/elput_logind.c b/src/lib/elput/elput_logind.c
index 18453a6..cf5c631 100644
--- a/src/lib/elput/elput_logind.c
+++ b/src/lib/elput/elput_logind.c
@@ -393,6 +393,7 @@ _logind_device_take(Elput_Manager *em, uint32_t major, uint32_t minor)
if (eldbus_message_error_get(reply, &errname, &errmsg))
{
ERR("Eldbus Message Error: %s %s", errname, errmsg);
+ eldbus_message_unref(reply);
return -1;
}