Bug 37861

Summary: Memory leak in collect_satisfied_requests in mcd-dispatch-operation.c
Product: Telepathy Reporter: Vivek Dasmohapatra <vivek>
Component: mission-controlAssignee: Vivek Dasmohapatra <vivek>
Status: RESOLVED FIXED QA Contact: Telepathy bugs list <telepathy-bugs>
Severity: minor    
Priority: medium Keywords: patch
Version: git master   
Hardware: Other   
OS: All   
URL: http://cgit.collabora.com/git/user/vivek/telepathy-mission-control/log/?h=cdo-satisfied-requests-hash-leak
Whiteboard: r+
i915 platform: i915 features:

Description Vivek Dasmohapatra 2011-06-02 11:16:19 UTC
A hash was allocated, and its contents borrowed and later
unreffed/freed, but the hash itself was never freed.
Comment 1 Simon McVittie 2011-06-03 01:39:13 UTC
Looks OK. One additional enhancement you could make:

> - g_ptr_array_unref (satisfied_requests);
> + free_satisfied_requests (satisfied_requests);

Consider giving satisfied_requests g_free as a free-function, which would mean the last unref automatically frees its contents.
Comment 2 Vivek Dasmohapatra 2011-06-08 11:17:25 UTC
Good point, amended.
Comment 3 Simon McVittie 2011-06-09 02:38:50 UTC
Also r+.
Comment 4 Will Thompson 2011-08-31 07:35:53 UTC
Released in 5.8.0; will be in 5.9.2 when it's released shortly.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.