Fix issue with some driver when performing action before opening a render view
With some drivers, glXCreateContextAttribsARB
does not returns NULL
on failure even if it should according to OpenGL specifications.
This MR forces the context to NULL
if an error occurs.
Edited by Michael Migliore