Detlef Riekenberg : ntdll/tests: Skip tests if NtCurrentTeb doesn't exist.

Alexandre Julliard julliard at wine.codeweavers.com
Thu Jan 12 06:43:23 CST 2006


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

Author: Detlef Riekenberg <wine.dev at web.de>
Date:   Thu Jan 12 13:29:49 2006 +0100

ntdll/tests: Skip tests if NtCurrentTeb doesn't exist.

---

 dlls/ntdll/tests/exception.c |    7 +++++--
 1 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/dlls/ntdll/tests/exception.c b/dlls/ntdll/tests/exception.c
index 0667e57..9cc431b 100644
--- a/dlls/ntdll/tests/exception.c
+++ b/dlls/ntdll/tests/exception.c
@@ -18,7 +18,6 @@
  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
  */
 
-#include <assert.h>
 #include <stdarg.h>
 
 #ifndef _WIN32_WINNT
@@ -202,7 +201,11 @@ static void test_prot_fault(void)
     } exc_frame;
 
     pNtCurrentTeb = (void *)GetProcAddress( GetModuleHandleA("ntdll.dll"), "NtCurrentTeb" );
-    assert( pNtCurrentTeb );
+    if (!pNtCurrentTeb)
+    {
+        trace( "NtCurrentTeb not found, skipping tests\n" );
+        return;
+    }
 
     exc_frame.frame.Handler = handler;
     exc_frame.frame.Prev = pNtCurrentTeb()->Tib.ExceptionList;




More information about the wine-cvs mailing list