Bug 11406 - Incorrect use of free() and realloc()
Summary: Incorrect use of free() and realloc()
Status: RESOLVED FIXED
Alias: None
Product: UIM
Classification: Unclassified
Component: bridge: GTK+ (show other bugs)
Version: unspecified
Hardware: All All
: medium normal
Assignee: Etsushi Kato
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-06-28 12:50 UTC by Christian Biere
Modified: 2007-06-29 23:17 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments
Fix for the described bug (1.56 KB, patch)
2007-06-28 12:52 UTC, Christian Biere
Details | Splinter Review

Description Christian Biere 2007-06-28 12:50:19 UTC
In gtk/compose.c and gtk/gtk-im-uim.c memory allocated through GLib is passed to free() and realloc(). This is incorrect as g_realloc() and g_free() must be used instead. Often g_realloc() and g_free() are mapped to free() and realloc() which hides this bug. Otherwise it causes crashes or memory corruption.
Comment 1 Christian Biere 2007-06-28 12:52:14 UTC
Created attachment 10488 [details] [review]
Fix for the described bug
Comment 2 Etsushi Kato 2007-06-29 23:11:16 UTC
Thanks for pointing out g_free() things.  I'll fix later.
Comment 3 Etsushi Kato 2007-06-29 23:17:41 UTC
Fixed in svn trunk at uim.googlecode.com.


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.