Module: Mesa
Branch: master
Commit: 8ce747defa2dafebfa99f03913342d6aca995341
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=8ce747defa2dafebfa99f03913342d6aca995341

Author: José Fonseca <jfons...@vmware.com>
Date:   Thu Feb 11 16:34:43 2010 +0000

gdi: Never fail at DLL load time.

Windows doesn't really expect things to fail at this point -- it
will try many times until it finally gives up, worse, something bad
happens.

The WGL state tracker will gracefully decline to do work even when it
is loaded.

---

 src/gallium/winsys/gdi/gdi_llvmpipe_winsys.c |   10 +++++-----
 src/gallium/winsys/gdi/gdi_softpipe_winsys.c |   10 +++++-----
 2 files changed, 10 insertions(+), 10 deletions(-)

diff --git a/src/gallium/winsys/gdi/gdi_llvmpipe_winsys.c 
b/src/gallium/winsys/gdi/gdi_llvmpipe_winsys.c
index 03dbd76..e9e5990 100644
--- a/src/gallium/winsys/gdi/gdi_llvmpipe_winsys.c
+++ b/src/gallium/winsys/gdi/gdi_llvmpipe_winsys.c
@@ -251,13 +251,13 @@ DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID 
lpReserved)
 {
    switch (fdwReason) {
    case DLL_PROCESS_ATTACH:
-      if (!stw_init(&stw_winsys)) {
-         return FALSE;
-      }
-      return stw_init_thread();
+      stw_init(&stw_winsys);
+      stw_init_thread();
+      break;
 
    case DLL_THREAD_ATTACH:
-      return stw_init_thread();
+      stw_init_thread();
+      break;
 
    case DLL_THREAD_DETACH:
       stw_cleanup_thread();
diff --git a/src/gallium/winsys/gdi/gdi_softpipe_winsys.c 
b/src/gallium/winsys/gdi/gdi_softpipe_winsys.c
index 2078020..71360e5 100644
--- a/src/gallium/winsys/gdi/gdi_softpipe_winsys.c
+++ b/src/gallium/winsys/gdi/gdi_softpipe_winsys.c
@@ -297,13 +297,13 @@ DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID 
lpReserved)
 {
    switch (fdwReason) {
    case DLL_PROCESS_ATTACH:
-      if (!stw_init(&stw_winsys)) {
-         return FALSE;
-      }
-      return stw_init_thread();
+      stw_init(&stw_winsys);
+      stw_init_thread();
+      break;
 
    case DLL_THREAD_ATTACH:
-      return stw_init_thread();
+      stw_init_thread();
+      break;
 
    case DLL_THREAD_DETACH:
       stw_cleanup_thread();

_______________________________________________
mesa-commit mailing list
mesa-commit@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-commit

Reply via email to