Moved the beginnings of some toolhelp exports to their own module.

svn path=/trunk/; revision=3935
This commit is contained in:
Robert Dickenson 2003-01-05 10:07:08 +00:00
parent 661896dfde
commit b9113d3fae
3 changed files with 97 additions and 45 deletions

View file

@ -1,4 +1,4 @@
# $Id: makefile,v 1.55 2002/12/08 16:07:18 robd Exp $
# $Id: makefile,v 1.56 2003/01/05 10:07:07 robd Exp $
PATH_TO_TOP = ../..
@ -32,7 +32,8 @@ SYNCH_OBJECTS = synch/critical.o synch/event.o synch/intrlck.o synch/mutex.o \
MISC_OBJECTS = misc/error.o misc/atom.o misc/handle.o misc/env.o \
misc/dllmain.o misc/comm.o misc/errormsg.o \
misc/console.o misc/time.o misc/stubs.o misc/ldr.o misc/res.o \
misc/console.o misc/time.o misc/toolhelp.o \
misc/stubs.o misc/ldr.o misc/res.o \
misc/debug.o misc/sysinfo.o misc/profile.o \
misc/mbchars.o misc/muldiv.o misc/getname.o

View file

@ -1,10 +1,9 @@
/* $Id: stubs.c,v 1.39 2003/01/04 18:33:18 robd Exp $
/* $Id: stubs.c,v 1.40 2003/01/05 10:07:08 robd Exp $
*
* KERNEL32.DLL stubs (unimplemented functions)
* Remove from this file, if you implement them.
*/
#include <windows.h>
#include <tlhelp32.h>
#define _OLE2NLS_IN_BUILD_
@ -1024,45 +1023,4 @@ VirtualBufferExceptionHandler (
return 0;
}
BOOL
STDCALL
Process32First(HANDLE hSnapshot, LPPROCESSENTRY32 lppe)
{
SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
return 0;
}
BOOL
STDCALL
Process32Next(HANDLE hSnapshot, LPPROCESSENTRY32 lppe)
{
SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
return 0;
}
BOOL
STDCALL
Process32FirstW(HANDLE hSnapshot, LPPROCESSENTRY32W lppe)
{
SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
return 0;
}
BOOL
STDCALL
Process32NextW(HANDLE hSnapshot, LPPROCESSENTRY32W lppe)
{
SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
return 0;
}
HANDLE
STDCALL
CreateToolhelp32Snapshot(DWORD dwFlags, DWORD th32ProcessID)
{
SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
return 0;
}
/* EOF */

View file

@ -0,0 +1,93 @@
/* $Id: toolhelp.c,v 1.1 2003/01/05 10:07:08 robd Exp $
*
* KERNEL32.DLL toolhelp functions
*
* COPYRIGHT: See COPYING in the top level directory
* PROJECT: ReactOS system libraries
* FILE: lib/kernel32/misc/toolhelp.c
* PURPOSE: Toolhelp functions
* PROGRAMMER: Robert Dickenson ( robd@mok.lvcm.com)
* UPDATE HISTORY:
* Created 05 January 2003
*/
#include <windows.h>
#include <tlhelp32.h>
BOOL
STDCALL
Process32First(HANDLE hSnapshot, LPPROCESSENTRY32 lppe)
{
SetLastError(ERROR_NO_MORE_FILES);
return FALSE;
}
BOOL
STDCALL
Process32Next(HANDLE hSnapshot, LPPROCESSENTRY32 lppe)
{
SetLastError(ERROR_NO_MORE_FILES);
return FALSE;
}
BOOL
STDCALL
Process32FirstW(HANDLE hSnapshot, LPPROCESSENTRY32W lppe)
{
if (!lppe || lppe->dwSize != sizeof(PROCESSENTRY32W)) {
SetLastError(ERROR_INVALID_PARAMETER);
return FALSE;
}
SetLastError(ERROR_NO_MORE_FILES);
return FALSE;
}
BOOL
STDCALL
Process32NextW(HANDLE hSnapshot, LPPROCESSENTRY32W lppe)
{
SetLastError(ERROR_NO_MORE_FILES);
return FALSE;
}
HANDLE
STDCALL
CreateToolhelp32Snapshot(DWORD dwFlags, DWORD th32ProcessID)
{
// return open handle to snapshot on success, -1 on failure
// the snapshot handle behavies like an object handle
HANDLE hSnapshot = -1;
if (dwFlags & TH32CS_INHERIT) {
}
// if (dwFlags & TH32CS_SNAPALL) { // == (TH32CS_SNAPHEAPLIST + TH32CS_SNAPMODULE + TH32CS_SNAPPROCESS + TH32CS_SNAPTHREAD)
// }
if (dwFlags & TH32CS_SNAPHEAPLIST) {
}
if (dwFlags & TH32CS_SNAPMODULE) {
}
if (dwFlags & TH32CS_SNAPPROCESS) {
}
if (dwFlags & TH32CS_SNAPTHREAD) {
}
SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
// caller must use CloseHandle to destroy the returned snapshot handle
return hSnapshot;
}
BOOL
WINAPI
Toolhelp32ReadProcessMemory(DWORD th32ProcessID,
LPCVOID lpBaseAddress, LPVOID lpBuffer,
DWORD cbRead, LPDWORD lpNumberOfBytesRead)
{
SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
return FALSE;
}
/* EOF */