[waffle] [PATCH 3/4] wgl: use correct dtor in wgl_window_priv_create error path

Emil Velikov emil.l.velikov at gmail.com
Tue Aug 12 08:37:34 PDT 2014


This is the private ctor, as such use the private dtor if we fail at any
point. Noticed while casing wgl_window_destroy() related bug in piglit.

Signed-off-by: Emil Velikov <emil.l.velikov at gmail.com>
---
 src/waffle/wgl/wgl_window.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/waffle/wgl/wgl_window.c b/src/waffle/wgl/wgl_window.c
index 43a49a4..a557c2f 100644
--- a/src/waffle/wgl/wgl_window.c
+++ b/src/waffle/wgl/wgl_window.c
@@ -134,7 +134,7 @@ wgl_window_priv_create(struct wcore_platform *wc_plat,
     return &self->wcore;
 
 error:
-    wgl_window_destroy(&self->wcore);
+    wgl_window_priv_destroy(&self->wcore);
     return NULL;
 }
 
-- 
2.0.2



More information about the waffle mailing list