diff --git a/dlls/d3d8/directx.c b/dlls/d3d8/directx.c index a85a965004e..6a4e9df3649 100644 --- a/dlls/d3d8/directx.c +++ b/dlls/d3d8/directx.c @@ -264,8 +264,10 @@ static void IDirect3D8Impl_FillGLCaps(LPDIRECT3D8 iface, Display* display) { case VENDOR_ATI: major = minor = 0; gl_string_cursor = strchr(gl_string, '-'); - if (gl_string_cursor++) { + if (gl_string_cursor) { int error = 0; + gl_string_cursor++; + /* Check if version number is of the form x.y.z */ if (*gl_string_cursor > '9' && *gl_string_cursor < '0') error = 1; diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c index a834d0e2f1d..36adf0c1a7d 100644 --- a/dlls/wined3d/device.c +++ b/dlls/wined3d/device.c @@ -3616,7 +3616,8 @@ ULONG WINAPI IWineD3DDeviceImpl_Release(IWineD3DDevice *iface) { TRACE("(%p) : Releasing from %ld\n", This, refCount + 1); if (!refCount) { - IWineD3DStateBlock_Release((IWineD3DStateBlock *)This->stateBlock); + /*TODO: Remove me once d3d8 stateblocks are converted */ + if (This->stateBlock) IWineD3DStateBlock_Release((IWineD3DStateBlock *)This->stateBlock); IWineD3D_Release(This->wineD3D); HeapFree(GetProcessHeap(), 0, This); }