Chris Robinson : wined3d:
Fix potential NULL dereference in IWineD3DSurfaceImpl_LockRect.
Alexandre Julliard
julliard at wine.codeweavers.com
Mon Jul 31 10:38:59 CDT 2006
Module: wine
Branch: refs/heads/master
Commit: 13557abb7fa2ba8173e4c6bd3b66f2881c43e7ff
URL: http://source.winehq.org/git/?p=wine.git;a=commit;h=13557abb7fa2ba8173e4c6bd3b66f2881c43e7ff
Author: Chris Robinson <chris.kcat at gmail.com>
Date: Mon Jul 31 06:36:55 2006 -0700
wined3d: Fix potential NULL dereference in IWineD3DSurfaceImpl_LockRect.
---
dlls/wined3d/surface.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/dlls/wined3d/surface.c b/dlls/wined3d/surface.c
index 67cd009..b11dda8 100644
--- a/dlls/wined3d/surface.c
+++ b/dlls/wined3d/surface.c
@@ -673,7 +673,7 @@ static HRESULT WINAPI IWineD3DSurfaceImp
/* NOTE: In a shared context environment the renderTarget will use the same context as the implicit swapchain (we're not in a shared environment yet! */
if ((swapchain == targetSwapChain && targetSwapChain != NULL) || iface == myDevice->renderTarget) {
- if (iface == swapchain->frontBuffer) {
+ if (swapchain && iface == swapchain->frontBuffer) {
TRACE("locking front\n");
glReadBuffer(GL_FRONT);
}
More information about the wine-cvs
mailing list