Commit 6ad6ce8d by apatrick@chromium.org

Fixed Display::initialize so it does not crash for devices that do not support PS 2.0.

The crash occurs when createDevice attempts to dereference mD3d9, which is NULL. Review URL: http://codereview.appspot.com/1956042 git-svn-id: https://angleproject.googlecode.com/svn/trunk@382 736b8ea6-26fd-11df-bfd4-992fa37f6226
parent c7b6eba9
......@@ -70,11 +70,10 @@ bool Display::initialize()
if (mDeviceCaps.PixelShaderVersion < D3DPS_VERSION(2, 0))
{
mD3d9->Release();
mD3d9 = NULL;
terminate();
return error(EGL_NOT_INITIALIZED, false);
}
else
{
mMinSwapInterval = 4;
mMaxSwapInterval = 0;
......@@ -150,7 +149,6 @@ bool Display::initialize()
mConfigSet.mSet.insert(configuration);
}
}
if (!createDevice())
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment