mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-11-11 03:10:09 +00:00
Fix a memory leak in gdk_display_open in the directfb backend
Patch by Andre Draszik, bug 609172
This commit is contained in:
parent
2dc9298b41
commit
7f483dbd7b
@ -93,15 +93,17 @@ GdkDisplay * gdk_display_open (const gchar *display_name)
|
||||
{
|
||||
DirectFBError ("gdk_display_open: GetDisplayLayer", ret);
|
||||
directfb->Release (directfb);
|
||||
directfb = NULL;
|
||||
_gdk_display->directfb = NULL;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
||||
ret=directfb->GetInputDevice (directfb, DIDID_KEYBOARD, &keyboard);
|
||||
|
||||
if (ret != DFB_OK){
|
||||
ret = directfb->GetInputDevice (directfb, DIDID_KEYBOARD, &keyboard);
|
||||
if (ret != DFB_OK)
|
||||
{
|
||||
DirectFBError ("gdk_display_open: GetInputDevice", ret);
|
||||
directfb->Release (directfb);
|
||||
_gdk_display->directfb = NULL;
|
||||
return NULL;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user