Bug 570130 - Memory leak in meta_display_free_window_prop_hooks
Memory leak in meta_display_free_window_prop_hooks
Status: RESOLVED FIXED
Product: metacity
Classification: Other
Component: general
trunk
Other All
: Normal normal
: ---
Assigned To: Metacity maintainers list
Metacity maintainers list
:
Depends on:
Blocks:
  Show dependency tree
 
Reported: 2009-02-01 19:10 UTC by Matt Kraai
Modified: 2009-02-01 21:05 UTC (History)
1 user (show)

See Also:
GNOME target: ---
GNOME version: 2.21/2.22


Attachments
Patch (676 bytes, patch)
2009-02-01 19:12 UTC, Matt Kraai
committed Details | Diff | Review

Description Matt Kraai 2009-02-01 19:10:00 UTC
Please describe the problem:
In meta_display_free_window_prop_hooks, display->prop_hooks_table is set to NULL before it is freed.  As a result, the table is never deallocated.  I'll attach a patch shortly which fixes this problem.

Steps to reproduce:
1. Call meta_display_init_window_prop_hooks.
2. Call meta_display_free_window_prop_hooks.
3. Profit!


Actual results:
The memory allocated for the hooks table is leaked.

Expected results:
The memory allocate for the hooks table would be freed.

Does this happen every time?
Yes.

Other information:
Comment 1 Matt Kraai 2009-02-01 19:12:25 UTC
Created attachment 127719 [details] [review]
Patch
Comment 2 Thomas Thurman 2009-02-01 21:05:06 UTC
Oops.  Committed with thanks.

Note You need to log in before you can comment on or make changes to this bug.