diff options
author | Michael Stahl <mstahl@redhat.com> | 2015-09-30 18:25:45 +0200 |
---|---|---|
committer | Andras Timar <andras.timar@collabora.com> | 2015-10-17 23:22:39 +0200 |
commit | c5d540773ddf8b764343cd58870ad2b08edcea49 (patch) | |
tree | 988fce6aec68205dd747e4de81767704c4be6d15 /include/vcl | |
parent | 0fb40e5e63e50faa95b390e17b0ed165b4e73611 (diff) |
vcl: clean up before error returns in OpenGLContext::ImplInit()
JunitTest_chart_unoapi fails here with "assert(!hasCurrent())" because
the initialization apparently fails due to lack of a
wglCreateContextAttribsARB in the VM, so ensure that the hTempRC is not
active and also deleted in all cases.
(cherry picked from commit 5efad73918152f380fa1bf1e2cd3bc06b6353683)
vcl: even in the newfangled OpenGL world, initializing members is ...
... still a good idea.
(cherry picked from commit 37d243651b7db5dc313686f474f4e7c92e2160ce)
Change-Id: I7e03b95d1146af48a24e34692c3c2827298fccee
Reviewed-on: https://gerrit.libreoffice.org/19040
Reviewed-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
Tested-by: Markus Mohrhard <markus.mohrhard@googlemail.com>
(cherry picked from commit 418d7171e1a1ad669c2d8ecfa75ae688a0bf9d70)
Diffstat (limited to 'include/vcl')
-rw-r--r-- | include/vcl/opengl/OpenGLContext.hxx | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/include/vcl/opengl/OpenGLContext.hxx b/include/vcl/opengl/OpenGLContext.hxx index 68d7209f6662..ce44aefa24b7 100644 --- a/include/vcl/opengl/OpenGLContext.hxx +++ b/include/vcl/opengl/OpenGLContext.hxx @@ -142,6 +142,9 @@ struct GLWindow GLWindow() : #if defined( _WIN32 ) + hWnd(NULL), + hDC(NULL), + hRC(NULL), #elif defined( MACOSX ) #elif defined( IOS ) #elif defined( ANDROID ) |