Merge lp://staging/~seb128/indicator-power/dont-leak-content into lp://staging/indicator-power/14.04

Proposed by Sebastien Bacher
Status: Merged
Approved by: Charles Kerr
Approved revision: 209
Merged at revision: 209
Proposed branch: lp://staging/~seb128/indicator-power/dont-leak-content
Merge into: lp://staging/indicator-power/14.04
Diff against target: 11 lines (+1/-0)
1 file modified
src/ib-brightness-control.c (+1/-0)
To merge this branch: bzr merge lp://staging/~seb128/indicator-power/dont-leak-content
Reviewer Review Type Date Requested Status
Charles Kerr (community) Approve
PS Jenkins bot (community) continuous-integration Approve
Review via email: mp+192581@code.staging.launchpad.net

Commit message

Don't leak the g_file_get_contents value, reported by valgrind

Description of the change

Don't leak the g_file_get_contents value, reported by valgrind

==17468== 4,097 bytes in 1 blocks are definitely lost in loss record 1,921 of 1,924
==17468== at 0x40299D8: malloc (in /usr/lib/valgrind/vgpreload_memcheck-x86-linux.so)
==17468== by 0x428562F: g_try_malloc (gmem.c:255)
==17468== by 0x426C7CE: g_file_get_contents (gfileutils.c:752)
==17468== by 0x8059DEE: ib_brightness_control_get_value_from_file (ib-brightness-control.c:122)
==17468== by 0x8059E76: ib_brightness_control_get_value (ib-brightness-control.c:140)
==17468== by 0x8057E53: action_state_for_brightness (service.c:473)
==17468== by 0x8057E7A: update_brightness_action_state (service.c:480)
==17468== by 0x80592FF: on_bus_acquired (service.c:526)
==17468== by 0x4143137: connection_get_cb (gdbusnameowning.c:480)
==17468== by 0x40DF294: g_simple_async_result_complete (gsimpleasyncresult.c:777)
==17468== by 0x40DF2FA: complete_in_idle_cb (gsimpleasyncresult.c:789)
==17468== by 0x427C59F: g_idle_dispatch (gmain.c:5250)
==17468== by 0x427F83D: g_main_context_dispatch (gmain.c:3065)
==17468== by 0x427FBE7: g_main_context_iterate.isra.22 (gmain.c:3712)
==17468== by 0x428004A: g_main_loop_run (gmain.c:3906)
==17468== by 0x4372904: (below main) (libc-start.c:260)

To post a comment you must log in.
Revision history for this message
PS Jenkins bot (ps-jenkins) wrote :
review: Approve (continuous-integration)
Revision history for this message
Charles Kerr (charlesk) wrote :

Nice catch!

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.

Subscribers

People subscribed via source and target branches