H. Verbeet : wined3d: Remove some redundant code.

Alexandre Julliard julliard at wine.codeweavers.com
Tue Jun 27 04:53:30 CDT 2006


Module: wine
Branch: refs/heads/master
Commit: 3489f1b9b1143433366a7d562e188dd2559ef6e3
URL:    http://source.winehq.org/git/?p=wine.git;a=commit;h=3489f1b9b1143433366a7d562e188dd2559ef6e3

Author: H. Verbeet <hverbeet at gmail.com>
Date:   Tue Jun 27 00:32:32 2006 +0200

wined3d: Remove some redundant code.

---

 dlls/wined3d/device.c |   13 ++++---------
 1 files changed, 4 insertions(+), 9 deletions(-)

diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c
index 9e0f00f..2be5692 100644
--- a/dlls/wined3d/device.c
+++ b/dlls/wined3d/device.c
@@ -1582,16 +1582,11 @@ #endif
     XFree(object->visInfo);
     object->visInfo = NULL;
 
-    if (NULL == object->glCtx) {
-        ERR("cannot create glxContext\n");
-        LEAVE_GL();
-        return WINED3DERR_NOTAVAILABLE;
-    }
-
     LEAVE_GL();
-    if (object->glCtx == NULL) {
-        ERR("Error in context creation !\n");
-        return WINED3DERR_INVALIDCALL;
+
+    if (!object->glCtx) {
+        ERR("Failed to create GLX context\n");
+        return WINED3DERR_NOTAVAILABLE;
     } else {
         TRACE("Context created (HWND=%p, glContext=%p, Window=%ld, VisInfo=%p)\n",
                 object->win_handle, object->glCtx, object->win, object->visInfo);




More information about the wine-cvs mailing list