Moved standard syslevel APIs declaration to winbase.h.
Use exported syslevel function wherever possible.
Moved SEGPTR declaration to windef16.h.
diff --git a/loader/task.c b/loader/task.c
index 4d3bf8d..7491088 100644
--- a/loader/task.c
+++ b/loader/task.c
@@ -27,8 +27,8 @@
#include "thread.h"
#include "toolhelp.h"
#include "winnt.h"
-#include "winsock.h"
#include "syslevel.h"
+#include "winsock.h"
#include "debugtools.h"
#include "services.h"
#include "server.h"
@@ -336,9 +336,9 @@
/* Add the task to the linked list */
- SYSLEVEL_EnterWin16Lock();
+ _EnterWin16Lock();
TASK_LinkTask( hTask );
- SYSLEVEL_LeaveWin16Lock();
+ _LeaveWin16Lock();
return TRUE;
}
@@ -384,12 +384,12 @@
DWORD lockCount;
/* Enter the Win16Lock to protect global data structures */
- SYSLEVEL_EnterWin16Lock();
+ _EnterWin16Lock();
pTask = (TDB *)GlobalLock16( GetCurrentTask() );
if ( !pTask )
{
- SYSLEVEL_LeaveWin16Lock();
+ _LeaveWin16Lock();
return;
}
@@ -486,7 +486,7 @@
enum { MODE_YIELD, MODE_SLEEP, MODE_WAKEUP } mode;
DWORD lockCount;
- SYSLEVEL_EnterWin16Lock();
+ _EnterWin16Lock();
/* Check what we need to do */
hOldTask = GetCurrentTask();
@@ -521,7 +521,7 @@
else
{
/* nothing to do */
- SYSLEVEL_LeaveWin16Lock();
+ _LeaveWin16Lock();
return;
}
}
@@ -555,7 +555,7 @@
if ( mode == MODE_YIELD && hNewTask && hNewTask == hCurrentTask )
{
TRACE("returning to the current task (%04x)\n", hCurrentTask );
- SYSLEVEL_LeaveWin16Lock();
+ _LeaveWin16Lock();
/* Allow Win32 threads to thunk down even while a Win16 task is
in a tight PeekMessage() or Yield() loop ... */
@@ -600,7 +600,7 @@
RestoreThunkLock( lockCount );
}
- SYSLEVEL_LeaveWin16Lock();
+ _LeaveWin16Lock();
}
/***********************************************************************