Safely abort when we don't succeed in creating a GL context.

Task-number: QTBUG-33363

Change-Id: Ia2b0c329157786cb4ec703989f12d2fdb1ce6bc8
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>