Windows NT 4.0 source code leak
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

63 lines
1.3 KiB

/* --------------------------------------------------------------------
Microsoft OS/2 LAN Manager
Copyright(c) Microsoft Corp., 1990
-------------------------------------------------------------------- */
/* --------------------------------------------------------------------
File : testhlp.cxx
Description :
These are the operating system specific helper routines for NT. This
isolates all of the operating system specific stuff from the testing
code.
History :
mikemon 01-14-91 Created this file.
-------------------------------------------------------------------- */
#include <ntos2.h>
#include <ntrtl.h>
#include <nturtl.h>
#include <testhlp.hxx>
void
TestHlpResumeThread (
int Thread
)
{
ULONG SuspendCount;
NtResumeThread((HANDLE) Thread,&SuspendCount);
}
int
TestHlpCurrentThread (
)
{
TEB * pTeb;
OBJECT_ATTRIBUTES ObjectAttributes;
void * Thread;
InitializeObjectAttributes(&ObjectAttributes,(PSTRING) 0,0,(HANDLE) 0,0);
pTeb = NtCurrentTeb();
NtOpenThread(&Thread,THREAD_ALL_ACCESS,&ObjectAttributes,
&(pTeb->ClientId));
return((int) Thread);
}
void
TestHlpSuspendThread (
int Thread
)
{
ULONG SuspendCount;
NtSuspendThread((HANDLE) Thread,&SuspendCount);
}