Converted to the new debug interface, using script written by Patrik

Stridvall.
This commit is contained in:
Alexandre Julliard 1999-05-23 10:25:25 +00:00
parent 158f00ed8d
commit 156570906f
42 changed files with 572 additions and 575 deletions

View File

@ -1,6 +1,6 @@
#include <stdlib.h> #include <stdlib.h>
#include <string.h> #include <string.h>
#include "debug.h" #include "debugtools.h"
#include "ntddk.h" #include "ntddk.h"
@ -25,7 +25,7 @@ NTSTATUS WINAPI NtOpenFile(
ULONG ShareAccess, ULONG ShareAccess,
ULONG OpenOptions) ULONG OpenOptions)
{ {
FIXME(ntdll,"(%p,0x%08lx,%p(%s),%p,0x%08lx,0x%08lx) stub\n", FIXME("(%p,0x%08lx,%p(%s),%p,0x%08lx,0x%08lx) stub\n",
FileHandle, DesiredAccess, ObjectAttributes, FileHandle, DesiredAccess, ObjectAttributes,
ObjectAttributes ? debugstr_w(ObjectAttributes->ObjectName->Buffer) : NULL, ObjectAttributes ? debugstr_w(ObjectAttributes->ObjectName->Buffer) : NULL,
IoStatusBlock, ShareAccess, OpenOptions); IoStatusBlock, ShareAccess, OpenOptions);
@ -64,7 +64,7 @@ NTSTATUS WINAPI NtCreateFile(
PVOID EaBuffer, PVOID EaBuffer,
ULONG EaLength) ULONG EaLength)
{ {
FIXME(ntdll,"(%p,0x%08lx,%p(%s),%p,%p,0x%08lx,0x%08lx,0x%08lx,0x%08lx,%p,0x%08lx) stub\n", FIXME("(%p,0x%08lx,%p(%s),%p,%p,0x%08lx,0x%08lx,0x%08lx,0x%08lx,%p,0x%08lx) stub\n",
FileHandle,DesiredAccess,ObjectAttributes, FileHandle,DesiredAccess,ObjectAttributes,
ObjectAttributes ? debugstr_w(ObjectAttributes->ObjectName->Buffer) : NULL, ObjectAttributes ? debugstr_w(ObjectAttributes->ObjectName->Buffer) : NULL,
IoStatusBlock,AllocateSize,FileAttributes, IoStatusBlock,AllocateSize,FileAttributes,
@ -98,7 +98,7 @@ NTSTATUS WINAPI NtReadFile (
PLARGE_INTEGER ByteOffset, PLARGE_INTEGER ByteOffset,
PULONG Key) PULONG Key)
{ {
FIXME(ntdll,"(0x%08x,0x%08x,%p,%p,%p,%p,0x%08lx,%p,%p),stub!\n", FIXME("(0x%08x,0x%08x,%p,%p,%p,%p,0x%08lx,%p,%p),stub!\n",
FileHandle,EventHandle,ApcRoutine,ApcContext,IoStatusBlock,Buffer,Length,ByteOffset,Key); FileHandle,EventHandle,ApcRoutine,ApcContext,IoStatusBlock,Buffer,Length,ByteOffset,Key);
return 0; return 0;
} }
@ -118,7 +118,7 @@ NTSTATUS WINAPI NtDeviceIoControlFile(
OUT PVOID OutputBuffer, OUT PVOID OutputBuffer,
IN ULONG OutputBufferSize) IN ULONG OutputBufferSize)
{ {
FIXME(ntdll,"(0x%08x,0x%08x,%p,%p,%p,0x%08lx,%p,0x%08lx,%p,0x%08lx): empty stub\n", FIXME("(0x%08x,0x%08x,%p,%p,%p,0x%08lx,%p,0x%08lx,%p,0x%08lx): empty stub\n",
DeviceHandle, Event, UserApcRoutine, UserApcContext, DeviceHandle, Event, UserApcRoutine, UserApcContext,
IoStatusBlock, IoControlCode, InputBuffer, InputBufferSize, OutputBuffer, OutputBufferSize); IoStatusBlock, IoControlCode, InputBuffer, InputBufferSize, OutputBuffer, OutputBufferSize);
return 0; return 0;
@ -139,7 +139,7 @@ NTSTATUS WINAPI NtFsControlFile(
OUT PVOID OutputBuffer, OUT PVOID OutputBuffer,
IN ULONG OutputBufferSize) IN ULONG OutputBufferSize)
{ {
FIXME(ntdll,"(0x%08x,0x%08x,%p,%p,%p,0x%08lx,%p,0x%08lx,%p,0x%08lx): stub\n", FIXME("(0x%08x,0x%08x,%p,%p,%p,0x%08lx,%p,0x%08lx,%p,0x%08lx): stub\n",
DeviceHandle,Event,ApcRoutine,ApcContext,IoStatusBlock,IoControlCode, DeviceHandle,Event,ApcRoutine,ApcContext,IoStatusBlock,IoControlCode,
InputBuffer,InputBufferSize,OutputBuffer,OutputBufferSize); InputBuffer,InputBufferSize,OutputBuffer,OutputBufferSize);
return 0; return 0;
@ -154,7 +154,7 @@ NTSTATUS WINAPI NtSetVolumeInformationFile(
PVOID VolumeInformation, PVOID VolumeInformation,
ULONG Length) ULONG Length)
{ {
FIXME(ntdll,"(0x%08x,%p,%p,0x%08lx) stub\n", FIXME("(0x%08x,%p,%p,0x%08lx) stub\n",
FileHandle,VolumeInformationClass,VolumeInformation,Length); FileHandle,VolumeInformationClass,VolumeInformation,Length);
return 0; return 0;
} }
@ -169,7 +169,7 @@ NTSTATUS WINAPI NtQueryInformationFile(
ULONG Length, ULONG Length,
FILE_INFORMATION_CLASS FileInformationClass) FILE_INFORMATION_CLASS FileInformationClass)
{ {
FIXME(ntdll,"(0x%08x,%p,%p,0x%08lx,0x%08x),stub!\n", FIXME("(0x%08x,%p,%p,0x%08lx,0x%08x),stub!\n",
FileHandle,IoStatusBlock,FileInformation,Length,FileInformationClass); FileHandle,IoStatusBlock,FileInformation,Length,FileInformationClass);
return 0; return 0;
} }
@ -184,7 +184,7 @@ NTSTATUS WINAPI NtSetInformationFile(
ULONG Length, ULONG Length,
FILE_INFORMATION_CLASS FileInformationClass) FILE_INFORMATION_CLASS FileInformationClass)
{ {
FIXME(ntdll,"(0x%08x,%p,%p,0x%08lx,0x%08x)\n", FIXME("(0x%08x,%p,%p,0x%08lx,0x%08x)\n",
FileHandle,IoStatusBlock,FileInformation,Length,FileInformationClass); FileHandle,IoStatusBlock,FileInformation,Length,FileInformationClass);
return 0; return 0;
} }
@ -206,7 +206,7 @@ NTSTATUS WINAPI NtQueryDirectoryFile(
IN PUNICODE_STRING FileName OPTIONAL, IN PUNICODE_STRING FileName OPTIONAL,
IN BOOLEAN RestartScan) IN BOOLEAN RestartScan)
{ {
FIXME (ntdll,"(0x%08x 0x%08x %p %p %p %p 0x%08lx 0x%08x 0x%08x %p 0x%08x\n", FIXME("(0x%08x 0x%08x %p %p %p %p 0x%08lx 0x%08x 0x%08x %p 0x%08x\n",
FileHandle, Event, ApcRoutine, ApcContext, IoStatusBlock, FileInformation, FileHandle, Event, ApcRoutine, ApcContext, IoStatusBlock, FileInformation,
Length, FileInformationClass, ReturnSingleEntry, Length, FileInformationClass, ReturnSingleEntry,
debugstr_w(FileName->Buffer),RestartScan); debugstr_w(FileName->Buffer),RestartScan);

View File

@ -11,7 +11,7 @@
#include <string.h> #include <string.h>
#include <time.h> #include <time.h>
#include "debugstr.h" #include "debugstr.h"
#include "debug.h" #include "debugtools.h"
#include "ntddk.h" #include "ntddk.h"
@ -33,7 +33,7 @@ NTSTATUS WINAPI NtCreateTimer(
IN POBJECT_ATTRIBUTES ObjectAttributes OPTIONAL, IN POBJECT_ATTRIBUTES ObjectAttributes OPTIONAL,
IN TIMER_TYPE TimerType) IN TIMER_TYPE TimerType)
{ {
FIXME(ntdll,"(%p,0x%08lx,%p(%s),0x%08x) stub\n", FIXME("(%p,0x%08lx,%p(%s),0x%08x) stub\n",
TimerHandle,DesiredAccess,ObjectAttributes, TimerHandle,DesiredAccess,ObjectAttributes,
ObjectAttributes ? debugstr_w(ObjectAttributes->ObjectName->Buffer) : NULL, ObjectAttributes ? debugstr_w(ObjectAttributes->ObjectName->Buffer) : NULL,
TimerType); TimerType);
@ -51,7 +51,7 @@ NTSTATUS WINAPI NtSetTimer(
IN ULONG Period OPTIONAL, IN ULONG Period OPTIONAL,
OUT PBOOLEAN PreviousState OPTIONAL) OUT PBOOLEAN PreviousState OPTIONAL)
{ {
FIXME(ntdll,"(0x%08x,%p,%p,%p,%08x,0x%08lx,%p) stub\n", FIXME("(0x%08x,%p,%p,%p,%08x,0x%08lx,%p) stub\n",
TimerHandle,DueTime,TimerApcRoutine,TimerContext,WakeTimer,Period,PreviousState); TimerHandle,DueTime,TimerApcRoutine,TimerContext,WakeTimer,Period,PreviousState);
return 0; return 0;
} }
@ -61,7 +61,7 @@ NTSTATUS WINAPI NtSetTimer(
*/ */
NTSTATUS WINAPI NtQueryTimerResolution(DWORD x1,DWORD x2,DWORD x3) NTSTATUS WINAPI NtQueryTimerResolution(DWORD x1,DWORD x2,DWORD x3)
{ {
FIXME(ntdll,"(0x%08lx,0x%08lx,0x%08lx), stub!\n",x1,x2,x3); FIXME("(0x%08lx,0x%08lx,0x%08lx), stub!\n",x1,x2,x3);
return 1; return 1;
} }
@ -79,7 +79,7 @@ NTSTATUS WINAPI NtTerminateProcess(
HANDLE ProcessHandle, HANDLE ProcessHandle,
LONG ExitStatus) LONG ExitStatus)
{ {
TRACE(ntdll, "0x%08x 0x%08lx\n", ProcessHandle, ExitStatus ); TRACE("0x%08x 0x%08lx\n", ProcessHandle, ExitStatus );
/* win32 (0x7fffffff) to nt (-1) */ /* win32 (0x7fffffff) to nt (-1) */
if ( NtCurrentProcess() == ProcessHandle ) if ( NtCurrentProcess() == ProcessHandle )
@ -99,7 +99,7 @@ NTSTATUS WINAPI NtQueryInformationProcess(
IN ULONG ProcessInformationLength, IN ULONG ProcessInformationLength,
OUT PULONG ReturnLength) OUT PULONG ReturnLength)
{ {
FIXME(ntdll,"(0x%08x,0x%08x,%p,0x%08lx,%p),stub!\n", FIXME("(0x%08x,0x%08x,%p,0x%08lx,%p),stub!\n",
ProcessHandle,ProcessInformationClass,ProcessInformation,ProcessInformationLength,ReturnLength); ProcessHandle,ProcessInformationClass,ProcessInformation,ProcessInformationLength,ReturnLength);
return 0; return 0;
} }
@ -113,7 +113,7 @@ NTSTATUS WINAPI NtSetInformationProcess(
IN PVOID ProcessInformation, IN PVOID ProcessInformation,
IN ULONG ProcessInformationLength) IN ULONG ProcessInformationLength)
{ {
FIXME(ntdll,"(0x%08x,0x%08x,%p,0x%08lx) stub\n", FIXME("(0x%08x,0x%08x,%p,0x%08lx) stub\n",
ProcessHandle,ProcessInformationClass,ProcessInformation,ProcessInformationLength); ProcessHandle,ProcessInformationClass,ProcessInformation,ProcessInformationLength);
return 0; return 0;
} }
@ -129,7 +129,7 @@ NTSTATUS WINAPI NtResumeThread(
IN HANDLE ThreadHandle, IN HANDLE ThreadHandle,
IN PULONG SuspendCount) IN PULONG SuspendCount)
{ {
FIXME(ntdll,"(0x%08x,%p),stub!\n", FIXME("(0x%08x,%p),stub!\n",
ThreadHandle,SuspendCount); ThreadHandle,SuspendCount);
return 0; return 0;
} }
@ -158,7 +158,7 @@ NTSTATUS WINAPI NtQueryInformationThread(
IN ULONG ThreadInformationLength, IN ULONG ThreadInformationLength,
OUT PULONG ReturnLength) OUT PULONG ReturnLength)
{ {
FIXME(ntdll,"(0x%08x,0x%08x,%p,0x%08lx,%p),stub!\n", FIXME("(0x%08x,0x%08x,%p,0x%08lx,%p),stub!\n",
ThreadHandle, ThreadInformationClass, ThreadInformation, ThreadHandle, ThreadInformationClass, ThreadInformation,
ThreadInformationLength, ReturnLength); ThreadInformationLength, ReturnLength);
return 0; return 0;
@ -173,7 +173,7 @@ NTSTATUS WINAPI NtSetInformationThread(
PVOID ThreadInformation, PVOID ThreadInformation,
ULONG ThreadInformationLength) ULONG ThreadInformationLength)
{ {
FIXME(ntdll,"(0x%08x,0x%08x,%p,0x%08lx),stub!\n", FIXME("(0x%08x,0x%08x,%p,0x%08lx),stub!\n",
ThreadHandle, ThreadInformationClass, ThreadInformation, ThreadInformationLength); ThreadHandle, ThreadInformationClass, ThreadInformation, ThreadInformationLength);
return 0; return 0;
} }
@ -193,7 +193,7 @@ NTSTATUS WINAPI NtDuplicateToken(
IN TOKEN_TYPE TokenType, IN TOKEN_TYPE TokenType,
OUT PHANDLE NewToken) OUT PHANDLE NewToken)
{ {
FIXME(ntdll,"(0x%08x,0x%08lx,%p,0x%08x,0x%08x,%p),stub!\n", FIXME("(0x%08x,0x%08lx,%p,0x%08x,0x%08x,%p),stub!\n",
ExistingToken, DesiredAccess, ObjectAttributes, ImpersonationLevel, ExistingToken, DesiredAccess, ObjectAttributes, ImpersonationLevel,
TokenType, NewToken); TokenType, NewToken);
return 0; return 0;
@ -207,7 +207,7 @@ NTSTATUS WINAPI NtOpenProcessToken(
DWORD DesiredAccess, DWORD DesiredAccess,
HANDLE *TokenHandle) HANDLE *TokenHandle)
{ {
FIXME(ntdll,"(0x%08x,0x%08lx,%p): stub\n", FIXME("(0x%08x,0x%08lx,%p): stub\n",
ProcessHandle,DesiredAccess, TokenHandle); ProcessHandle,DesiredAccess, TokenHandle);
*TokenHandle = 0xcafe; *TokenHandle = 0xcafe;
return 0; return 0;
@ -222,7 +222,7 @@ NTSTATUS WINAPI NtOpenThreadToken(
BOOLEAN OpenAsSelf, BOOLEAN OpenAsSelf,
HANDLE *TokenHandle) HANDLE *TokenHandle)
{ {
FIXME(ntdll,"(0x%08x,0x%08lx,0x%08x,%p): stub\n", FIXME("(0x%08x,0x%08lx,0x%08x,%p): stub\n",
ThreadHandle,DesiredAccess, OpenAsSelf, TokenHandle); ThreadHandle,DesiredAccess, OpenAsSelf, TokenHandle);
*TokenHandle = 0xcafe; *TokenHandle = 0xcafe;
return 0; return 0;
@ -241,7 +241,7 @@ NTSTATUS WINAPI NtAdjustPrivilegesToken(
OUT PTOKEN_PRIVILEGES PreviousState, OUT PTOKEN_PRIVILEGES PreviousState,
OUT PDWORD ReturnLength) OUT PDWORD ReturnLength)
{ {
FIXME(ntdll,"(0x%08x,0x%08x,%p,0x%08lx,%p,%p),stub!\n", FIXME("(0x%08x,0x%08x,%p,0x%08lx,%p,%p),stub!\n",
TokenHandle, DisableAllPrivileges, NewState, BufferLength, PreviousState, ReturnLength); TokenHandle, DisableAllPrivileges, NewState, BufferLength, PreviousState, ReturnLength);
return 0; return 0;
} }
@ -257,7 +257,7 @@ NTSTATUS WINAPI NtQueryInformationToken(
DWORD tokeninfolength, DWORD tokeninfolength,
LPDWORD retlen ) LPDWORD retlen )
{ {
FIXME(ntdll,"(%08x,%ld,%p,%ld,%p): stub\n", FIXME("(%08x,%ld,%p,%ld,%p): stub\n",
token,tokeninfoclass,tokeninfo,tokeninfolength,retlen); token,tokeninfoclass,tokeninfo,tokeninfolength,retlen);
switch (tokeninfoclass) switch (tokeninfoclass)
@ -295,7 +295,7 @@ NTSTATUS WINAPI NtCreateSection(
IN ULONG AllocationAttributes, IN ULONG AllocationAttributes,
IN HANDLE FileHandle OPTIONAL) IN HANDLE FileHandle OPTIONAL)
{ {
FIXME(ntdll,"(%p,0x%08lx,%p(%s),%p,0x%08lx,0x%08lx,0x%08x) stub\n", FIXME("(%p,0x%08lx,%p(%s),%p,0x%08lx,0x%08lx,0x%08x) stub\n",
SectionHandle,DesiredAccess,ObjectAttributes, SectionHandle,DesiredAccess,ObjectAttributes,
ObjectAttributes ? debugstr_w(ObjectAttributes->ObjectName->Buffer) : NULL, ObjectAttributes ? debugstr_w(ObjectAttributes->ObjectName->Buffer) : NULL,
MaximumSize,SectionPageProtection,AllocationAttributes,FileHandle); MaximumSize,SectionPageProtection,AllocationAttributes,FileHandle);
@ -310,7 +310,7 @@ NTSTATUS WINAPI NtOpenSection(
ACCESS_MASK DesiredAccess, ACCESS_MASK DesiredAccess,
POBJECT_ATTRIBUTES ObjectAttributes) POBJECT_ATTRIBUTES ObjectAttributes)
{ {
FIXME(ntdll,"(%p,0x%08lx,%p(%s)),stub!\n", FIXME("(%p,0x%08lx,%p(%s)),stub!\n",
SectionHandle,DesiredAccess,ObjectAttributes, SectionHandle,DesiredAccess,ObjectAttributes,
ObjectAttributes ? debugstr_w(ObjectAttributes->ObjectName->Buffer) : NULL); ObjectAttributes ? debugstr_w(ObjectAttributes->ObjectName->Buffer) : NULL);
return 0; return 0;
@ -326,7 +326,7 @@ NTSTATUS WINAPI NtQuerySection(
IN ULONG Length, IN ULONG Length,
OUT PULONG ResultLength) OUT PULONG ResultLength)
{ {
FIXME(ntdll,"(0x%08x,%p,%p,0x%08lx,%p) stub!\n", FIXME("(0x%08x,%p,%p,0x%08lx,%p) stub!\n",
SectionHandle,SectionInformationClass,SectionInformation,Length,ResultLength); SectionHandle,SectionInformationClass,SectionInformation,Length,ResultLength);
return 0; return 0;
} }
@ -362,7 +362,7 @@ NTSTATUS WINAPI NtMapViewOfSection(
ULONG AllocationType, ULONG AllocationType,
ULONG Protect) ULONG Protect)
{ {
FIXME(ntdll,"(0x%08x,0x%08x,%p,0x%08lx,0x%08lx,%p,%p,0x%08x,0x%08lx,0x%08lx) stub\n", FIXME("(0x%08x,0x%08x,%p,0x%08lx,0x%08lx,%p,%p,0x%08x,0x%08lx,0x%08lx) stub\n",
SectionHandle,ProcessHandle,BaseAddress,ZeroBits,CommitSize,SectionOffset, SectionHandle,ProcessHandle,BaseAddress,ZeroBits,CommitSize,SectionOffset,
ViewSize,InheritDisposition,AllocationType,Protect); ViewSize,InheritDisposition,AllocationType,Protect);
return 0; return 0;
@ -377,7 +377,7 @@ NTSTATUS WINAPI NtMapViewOfSection(
*/ */
NTSTATUS WINAPI NtCreatePort(DWORD x1,DWORD x2,DWORD x3,DWORD x4,DWORD x5) NTSTATUS WINAPI NtCreatePort(DWORD x1,DWORD x2,DWORD x3,DWORD x4,DWORD x5)
{ {
FIXME(ntdll,"(0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx),stub!\n",x1,x2,x3,x4,x5); FIXME("(0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx),stub!\n",x1,x2,x3,x4,x5);
return 0; return 0;
} }
@ -386,7 +386,7 @@ NTSTATUS WINAPI NtCreatePort(DWORD x1,DWORD x2,DWORD x3,DWORD x4,DWORD x5)
*/ */
NTSTATUS WINAPI NtConnectPort(DWORD x1,PUNICODE_STRING uni,DWORD x3,DWORD x4,DWORD x5,DWORD x6,DWORD x7,DWORD x8) NTSTATUS WINAPI NtConnectPort(DWORD x1,PUNICODE_STRING uni,DWORD x3,DWORD x4,DWORD x5,DWORD x6,DWORD x7,DWORD x8)
{ {
FIXME(ntdll,"(0x%08lx,%s,0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx),stub!\n", FIXME("(0x%08lx,%s,0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx),stub!\n",
x1,debugstr_w(uni->Buffer),x3,x4,x5,x6,x7,x8); x1,debugstr_w(uni->Buffer),x3,x4,x5,x6,x7,x8);
return 0; return 0;
} }
@ -396,7 +396,7 @@ NTSTATUS WINAPI NtConnectPort(DWORD x1,PUNICODE_STRING uni,DWORD x3,DWORD x4,DWO
*/ */
NTSTATUS WINAPI NtListenPort(DWORD x1,DWORD x2) NTSTATUS WINAPI NtListenPort(DWORD x1,DWORD x2)
{ {
FIXME(ntdll,"(0x%08lx,0x%08lx),stub!\n",x1,x2); FIXME("(0x%08lx,0x%08lx),stub!\n",x1,x2);
return 0; return 0;
} }
@ -405,7 +405,7 @@ NTSTATUS WINAPI NtListenPort(DWORD x1,DWORD x2)
*/ */
NTSTATUS WINAPI NtAcceptConnectPort(DWORD x1,DWORD x2,DWORD x3,DWORD x4,DWORD x5,DWORD x6) NTSTATUS WINAPI NtAcceptConnectPort(DWORD x1,DWORD x2,DWORD x3,DWORD x4,DWORD x5,DWORD x6)
{ {
FIXME(ntdll,"(0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx),stub!\n",x1,x2,x3,x4,x5,x6); FIXME("(0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx),stub!\n",x1,x2,x3,x4,x5,x6);
return 0; return 0;
} }
@ -414,7 +414,7 @@ NTSTATUS WINAPI NtAcceptConnectPort(DWORD x1,DWORD x2,DWORD x3,DWORD x4,DWORD x5
*/ */
NTSTATUS WINAPI NtCompleteConnectPort(DWORD x1) NTSTATUS WINAPI NtCompleteConnectPort(DWORD x1)
{ {
FIXME(ntdll,"(0x%08lx),stub!\n",x1); FIXME("(0x%08lx),stub!\n",x1);
return 0; return 0;
} }
@ -423,7 +423,7 @@ NTSTATUS WINAPI NtCompleteConnectPort(DWORD x1)
*/ */
NTSTATUS WINAPI NtRegisterThreadTerminatePort(DWORD x1) NTSTATUS WINAPI NtRegisterThreadTerminatePort(DWORD x1)
{ {
FIXME(ntdll,"(0x%08lx),stub!\n",x1); FIXME("(0x%08lx),stub!\n",x1);
return 0; return 0;
} }
@ -432,7 +432,7 @@ NTSTATUS WINAPI NtRegisterThreadTerminatePort(DWORD x1)
*/ */
NTSTATUS WINAPI NtRequestWaitReplyPort(DWORD x1,DWORD x2,DWORD x3) NTSTATUS WINAPI NtRequestWaitReplyPort(DWORD x1,DWORD x2,DWORD x3)
{ {
FIXME(ntdll,"(0x%08lx,0x%08lx,0x%08lx),stub!\n",x1,x2,x3); FIXME("(0x%08lx,0x%08lx,0x%08lx),stub!\n",x1,x2,x3);
return 0; return 0;
} }
@ -441,7 +441,7 @@ NTSTATUS WINAPI NtRequestWaitReplyPort(DWORD x1,DWORD x2,DWORD x3)
*/ */
NTSTATUS WINAPI NtReplyWaitReceivePort(DWORD x1,DWORD x2,DWORD x3,DWORD x4) NTSTATUS WINAPI NtReplyWaitReceivePort(DWORD x1,DWORD x2,DWORD x3,DWORD x4)
{ {
FIXME(ntdll,"(0x%08lx,0x%08lx,0x%08lx,0x%08lx),stub!\n",x1,x2,x3,x4); FIXME("(0x%08lx,0x%08lx,0x%08lx,0x%08lx),stub!\n",x1,x2,x3,x4);
return 0; return 0;
} }
@ -453,7 +453,7 @@ NTSTATUS WINAPI NtReplyWaitReceivePort(DWORD x1,DWORD x2,DWORD x3,DWORD x4)
* NtSetIntervalProfile [NTDLL] * NtSetIntervalProfile [NTDLL]
*/ */
NTSTATUS WINAPI NtSetIntervalProfile(DWORD x1,DWORD x2) { NTSTATUS WINAPI NtSetIntervalProfile(DWORD x1,DWORD x2) {
FIXME(ntdll,"(0x%08lx,0x%08lx),stub!\n",x1,x2); FIXME("(0x%08lx,0x%08lx),stub!\n",x1,x2);
return 0; return 0;
} }
@ -464,7 +464,7 @@ NTSTATUS WINAPI NtQueryPerformanceCounter(
IN PLARGE_INTEGER Counter, IN PLARGE_INTEGER Counter,
IN PLARGE_INTEGER Frequency) IN PLARGE_INTEGER Frequency)
{ {
FIXME(ntdll,"(%p, 0%p) stub\n", FIXME("(%p, 0%p) stub\n",
Counter, Frequency); Counter, Frequency);
return 0; return 0;
} }
@ -474,7 +474,7 @@ NTSTATUS WINAPI NtQueryPerformanceCounter(
*/ */
NTSTATUS WINAPI NtCreateMailslotFile(DWORD x1,DWORD x2,DWORD x3,DWORD x4,DWORD x5,DWORD x6,DWORD x7,DWORD x8) NTSTATUS WINAPI NtCreateMailslotFile(DWORD x1,DWORD x2,DWORD x3,DWORD x4,DWORD x5,DWORD x6,DWORD x7,DWORD x8)
{ {
FIXME(ntdll,"(0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx),stub!\n",x1,x2,x3,x4,x5,x6,x7,x8); FIXME("(0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx),stub!\n",x1,x2,x3,x4,x5,x6,x7,x8);
return 0; return 0;
} }
@ -501,7 +501,7 @@ NTSTATUS WINAPI NtQuerySystemInformation(
IN ULONG Length, IN ULONG Length,
OUT PULONG ResultLength) OUT PULONG ResultLength)
{ {
FIXME(ntdll,"(0x%08x,%p,0x%08lx,%p) stub\n", FIXME("(0x%08x,%p,0x%08lx,%p) stub\n",
SystemInformationClass,SystemInformation,Length,ResultLength); SystemInformationClass,SystemInformation,Length,ResultLength);
ZeroMemory (SystemInformation, Length); ZeroMemory (SystemInformation, Length);
return 0; return 0;
@ -517,7 +517,7 @@ NTSTATUS WINAPI NtCreatePagingFile(
IN ULONG MaxiumSize, IN ULONG MaxiumSize,
OUT PULONG ActualSize) OUT PULONG ActualSize)
{ {
FIXME(ntdll,"(%p(%s),0x%08lx,0x%08lx,%p),stub!\n", FIXME("(%p(%s),0x%08lx,0x%08lx,%p),stub!\n",
PageFileName->Buffer, debugstr_w(PageFileName->Buffer),MiniumSize,MaxiumSize,ActualSize); PageFileName->Buffer, debugstr_w(PageFileName->Buffer),MiniumSize,MaxiumSize,ActualSize);
return 0; return 0;
} }
@ -530,7 +530,7 @@ NTSTATUS WINAPI NtCreatePagingFile(
NTSTATUS WINAPI NtDisplayString ( NTSTATUS WINAPI NtDisplayString (
PUNICODE_STRING string) PUNICODE_STRING string)
{ {
TRACE(ntdll,"%p(%s)\n",string->Buffer, debugstr_w(string->Buffer)); TRACE("%p(%s)\n",string->Buffer, debugstr_w(string->Buffer));
WriteConsoleW(GetStdHandle(STD_OUTPUT_HANDLE), string->Buffer, string->Length, 0, 0); WriteConsoleW(GetStdHandle(STD_OUTPUT_HANDLE), string->Buffer, string->Length, 0, 0);
return 0; return 0;
} }

View File

@ -4,7 +4,7 @@
#include <stdlib.h> #include <stdlib.h>
#include <string.h> #include <string.h>
#include "debug.h" #include "debugtools.h"
#include "ntddk.h" #include "ntddk.h"
@ -27,7 +27,7 @@ NTSTATUS WINAPI NtQueryObject(
IN ULONG Length, IN ULONG Length,
OUT PULONG ResultLength) OUT PULONG ResultLength)
{ {
FIXME(ntdll,"(0x%08x,0x%08x,%p,0x%08lx,%p): stub\n", FIXME("(0x%08x,0x%08x,%p,0x%08lx,%p): stub\n",
ObjectHandle, ObjectInformationClass, ObjectInformation, Length, ResultLength); ObjectHandle, ObjectInformationClass, ObjectInformation, Length, ResultLength);
return 0; return 0;
} }
@ -37,7 +37,7 @@ NTSTATUS WINAPI NtQueryObject(
*/ */
NTSTATUS WINAPI NtQuerySecurityObject(DWORD x1,DWORD x2,DWORD x3,DWORD x4,DWORD x5) NTSTATUS WINAPI NtQuerySecurityObject(DWORD x1,DWORD x2,DWORD x3,DWORD x4,DWORD x5)
{ {
FIXME(ntdll,"(0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx) stub!\n",x1,x2,x3,x4,x5); FIXME("(0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx) stub!\n",x1,x2,x3,x4,x5);
return 0; return 0;
} }
/****************************************************************************** /******************************************************************************
@ -52,7 +52,7 @@ NTSTATUS WINAPI NtDuplicateObject(
IN BOOLEAN InheritHandle, IN BOOLEAN InheritHandle,
ULONG Options) ULONG Options)
{ {
FIXME(ntdll,"(0x%08x,%p,0x%08x,%p,0x%08lx,0x%08x,0x%08lx) stub!\n", FIXME("(0x%08x,%p,0x%08x,%p,0x%08lx,0x%08x,0x%08lx) stub!\n",
SourceProcessHandle,SourceHandle,TargetProcessHandle,TargetHandle, SourceProcessHandle,SourceHandle,TargetProcessHandle,TargetHandle,
DesiredAccess,InheritHandle,Options); DesiredAccess,InheritHandle,Options);
*TargetHandle = 0; *TargetHandle = 0;
@ -68,7 +68,7 @@ NTSTATUS WINAPI NtDuplicateObject(
NTSTATUS WINAPI NtClose( NTSTATUS WINAPI NtClose(
HANDLE Handle) HANDLE Handle)
{ {
FIXME(ntdll,"(0x%08x),stub!\n",Handle); FIXME("(0x%08x),stub!\n",Handle);
return 1; return 1;
} }
@ -80,7 +80,7 @@ NTSTATUS WINAPI NtWaitForSingleObject(
IN BOOLEAN Alertable, IN BOOLEAN Alertable,
IN PLARGE_INTEGER Time) IN PLARGE_INTEGER Time)
{ {
FIXME(ntdll,"(%p,0x%08x,%p),stub!\n",Object,Alertable,Time); FIXME("(%p,0x%08x,%p),stub!\n",Object,Alertable,Time);
return 0; return 0;
} }
@ -102,7 +102,7 @@ NTSTATUS WINAPI NtOpenDirectoryObject(
ACCESS_MASK DesiredAccess, ACCESS_MASK DesiredAccess,
POBJECT_ATTRIBUTES ObjectAttributes) POBJECT_ATTRIBUTES ObjectAttributes)
{ {
FIXME(ntdll,"(%p,0x%08lx,%p(%s)): stub\n", FIXME("(%p,0x%08lx,%p(%s)): stub\n",
DirectoryHandle, DesiredAccess, ObjectAttributes, DirectoryHandle, DesiredAccess, ObjectAttributes,
ObjectAttributes ? debugstr_w(ObjectAttributes->ObjectName->Buffer) : NULL); ObjectAttributes ? debugstr_w(ObjectAttributes->ObjectName->Buffer) : NULL);
return 0; return 0;
@ -116,7 +116,7 @@ NTSTATUS WINAPI NtCreateDirectoryObject(
ACCESS_MASK DesiredAccess, ACCESS_MASK DesiredAccess,
POBJECT_ATTRIBUTES ObjectAttributes) POBJECT_ATTRIBUTES ObjectAttributes)
{ {
FIXME(ntdll,"(%p,0x%08lx,%p(%s)),stub!\n", FIXME("(%p,0x%08lx,%p(%s)),stub!\n",
DirectoryHandle,DesiredAccess,ObjectAttributes, DirectoryHandle,DesiredAccess,ObjectAttributes,
ObjectAttributes ? debugstr_w(ObjectAttributes->ObjectName->Buffer) : NULL); ObjectAttributes ? debugstr_w(ObjectAttributes->ObjectName->Buffer) : NULL);
return 0; return 0;
@ -144,7 +144,7 @@ NTSTATUS WINAPI NtQueryDirectoryObject(
IN OUT PULONG ObjectIndex, IN OUT PULONG ObjectIndex,
OUT PULONG DataWritten OPTIONAL) OUT PULONG DataWritten OPTIONAL)
{ {
FIXME(ntdll,"(0x%08x,%p,0x%08lx,0x%08x,0x%08x,%p,%p) stub\n", FIXME("(0x%08x,%p,0x%08lx,0x%08x,0x%08x,%p,%p) stub\n",
DirObjHandle, DirObjInformation, BufferLength, GetNextIndex, DirObjHandle, DirObjInformation, BufferLength, GetNextIndex,
IgnoreInputIndex, ObjectIndex, DataWritten); IgnoreInputIndex, ObjectIndex, DataWritten);
return 0xc0000000; /* We don't have any. Whatever. (Yet.) */ return 0xc0000000; /* We don't have any. Whatever. (Yet.) */
@ -162,7 +162,7 @@ NTSTATUS WINAPI NtOpenSymbolicLinkObject(
IN ACCESS_MASK DesiredAccess, IN ACCESS_MASK DesiredAccess,
IN POBJECT_ATTRIBUTES ObjectAttributes) IN POBJECT_ATTRIBUTES ObjectAttributes)
{ {
FIXME(ntdll,"(%p,0x%08lx,%p(%s)) stub\n", FIXME("(%p,0x%08lx,%p(%s)) stub\n",
LinkHandle, DesiredAccess, ObjectAttributes, LinkHandle, DesiredAccess, ObjectAttributes,
ObjectAttributes ? debugstr_w(ObjectAttributes->ObjectName->Buffer) : NULL); ObjectAttributes ? debugstr_w(ObjectAttributes->ObjectName->Buffer) : NULL);
return 0; return 0;
@ -177,7 +177,7 @@ NTSTATUS WINAPI NtCreateSymbolicLinkObject(
IN POBJECT_ATTRIBUTES ObjectAttributes, IN POBJECT_ATTRIBUTES ObjectAttributes,
IN PUNICODE_STRING Name) IN PUNICODE_STRING Name)
{ {
FIXME(ntdll,"(%p,0x%08lx,%p(%s), %p) stub\n", FIXME("(%p,0x%08lx,%p(%s), %p) stub\n",
SymbolicLinkHandle, DesiredAccess, ObjectAttributes, SymbolicLinkHandle, DesiredAccess, ObjectAttributes,
ObjectAttributes ? debugstr_w(ObjectAttributes->ObjectName->Buffer) : NULL, ObjectAttributes ? debugstr_w(ObjectAttributes->ObjectName->Buffer) : NULL,
debugstr_w(Name->Buffer)); debugstr_w(Name->Buffer));
@ -192,7 +192,7 @@ NTSTATUS WINAPI NtQuerySymbolicLinkObject(
IN OUT PUNICODE_STRING LinkTarget, IN OUT PUNICODE_STRING LinkTarget,
OUT PULONG ReturnedLength OPTIONAL) OUT PULONG ReturnedLength OPTIONAL)
{ {
FIXME(ntdll,"(0x%08x,%p,%p) stub\n", FIXME("(0x%08x,%p,%p) stub\n",
LinkHandle, debugstr_w(LinkTarget->Buffer), ReturnedLength); LinkHandle, debugstr_w(LinkTarget->Buffer), ReturnedLength);
return 0; return 0;

View File

@ -2,7 +2,7 @@
* registry functions * registry functions
*/ */
#include "debug.h" #include "debugtools.h"
#include "winreg.h" #include "winreg.h"
#include "ntddk.h" #include "ntddk.h"
@ -23,7 +23,7 @@ NTSTATUS WINAPI NtCreateKey(
ULONG CreateOptions, ULONG CreateOptions,
PULONG Disposition) PULONG Disposition)
{ {
FIXME(ntdll,"(%p,0x%08lx,%p (%s),0x%08lx, %p(%s),0x%08lx,%p),stub!\n", FIXME("(%p,0x%08lx,%p (%s),0x%08lx, %p(%s),0x%08lx,%p),stub!\n",
KeyHandle, DesiredAccess, ObjectAttributes,debugstr_w(ObjectAttributes->ObjectName->Buffer), KeyHandle, DesiredAccess, ObjectAttributes,debugstr_w(ObjectAttributes->ObjectName->Buffer),
TitleIndex, Class, debugstr_w(Class->Buffer), CreateOptions, Disposition); TitleIndex, Class, debugstr_w(Class->Buffer), CreateOptions, Disposition);
return 0; return 0;
@ -35,7 +35,7 @@ NTSTATUS WINAPI NtCreateKey(
*/ */
NTSTATUS NtDeleteKey(HANDLE KeyHandle) NTSTATUS NtDeleteKey(HANDLE KeyHandle)
{ {
FIXME(ntdll,"(0x%08x) stub!\n", FIXME("(0x%08x) stub!\n",
KeyHandle); KeyHandle);
return 1; return 1;
} }
@ -48,7 +48,7 @@ NTSTATUS WINAPI NtDeleteValueKey(
IN HANDLE KeyHandle, IN HANDLE KeyHandle,
IN PUNICODE_STRING ValueName) IN PUNICODE_STRING ValueName)
{ {
FIXME(ntdll,"(0x%08x,%p(%s)) stub!\n", FIXME("(0x%08x,%p(%s)) stub!\n",
KeyHandle, ValueName,debugstr_w(ValueName->Buffer)); KeyHandle, ValueName,debugstr_w(ValueName->Buffer));
return 1; return 1;
@ -65,7 +65,7 @@ NTSTATUS WINAPI NtEnumerateKey(
ULONG Length, ULONG Length,
PULONG ResultLength) PULONG ResultLength)
{ {
FIXME(ntdll,"(0x%08x,0x%08lx,0x%08x,%p,0x%08lx,%p) stub\n", FIXME("(0x%08x,0x%08lx,0x%08x,%p,0x%08lx,%p) stub\n",
KeyHandle, Index, KeyInformationClass, KeyInformation, Length, ResultLength); KeyHandle, Index, KeyInformationClass, KeyInformation, Length, ResultLength);
return 1; return 1;
} }
@ -82,7 +82,7 @@ NTSTATUS WINAPI NtEnumerateValueKey(
ULONG Length, ULONG Length,
PULONG ResultLength) PULONG ResultLength)
{ {
FIXME(ntdll,"(0x%08x,0x%08lx,0x%08x,%p,0x%08lx,%p) stub!\n", FIXME("(0x%08x,0x%08lx,0x%08x,%p,0x%08lx,%p) stub!\n",
KeyHandle, Index, KeyInformationClass, KeyInformation, Length, ResultLength); KeyHandle, Index, KeyInformationClass, KeyInformation, Length, ResultLength);
return 1; return 1;
} }
@ -93,7 +93,7 @@ NTSTATUS WINAPI NtEnumerateValueKey(
*/ */
NTSTATUS NtFlushKey(HANDLE KeyHandle) NTSTATUS NtFlushKey(HANDLE KeyHandle)
{ {
FIXME(ntdll,"(0x%08x) stub!\n", FIXME("(0x%08x) stub!\n",
KeyHandle); KeyHandle);
return 1; return 1;
} }
@ -106,7 +106,7 @@ NTSTATUS WINAPI NtLoadKey(
PHANDLE KeyHandle, PHANDLE KeyHandle,
POBJECT_ATTRIBUTES ObjectAttributes) POBJECT_ATTRIBUTES ObjectAttributes)
{ {
FIXME(ntdll,"(%p,%p (%s)),stub!\n", FIXME("(%p,%p (%s)),stub!\n",
KeyHandle, ObjectAttributes,debugstr_w(ObjectAttributes->ObjectName->Buffer)); KeyHandle, ObjectAttributes,debugstr_w(ObjectAttributes->ObjectName->Buffer));
return 0; return 0;
@ -128,7 +128,7 @@ NTSTATUS WINAPI NtNotifyChangeKey(
IN ULONG Length, IN ULONG Length,
IN BOOLEAN WatchSubtree) IN BOOLEAN WatchSubtree)
{ {
FIXME(ntdll,"(0x%08x,0x%08x,%p,%p,%p,0x%08lx, 0x%08x,%p,0x%08lx,0x%08x) stub!\n", FIXME("(0x%08x,0x%08x,%p,%p,%p,0x%08lx, 0x%08x,%p,0x%08lx,0x%08x) stub!\n",
KeyHandle, Event, ApcRoutine, ApcContext, IoStatusBlock, CompletionFilter, KeyHandle, Event, ApcRoutine, ApcContext, IoStatusBlock, CompletionFilter,
Asynchroneous, ChangeBuffer, Length, WatchSubtree); Asynchroneous, ChangeBuffer, Length, WatchSubtree);
return 0; return 0;
@ -147,7 +147,7 @@ NTSTATUS WINAPI NtOpenKey(
ACCESS_MASK DesiredAccess, ACCESS_MASK DesiredAccess,
POBJECT_ATTRIBUTES ObjectAttributes) POBJECT_ATTRIBUTES ObjectAttributes)
{ {
FIXME(ntdll,"(%p,0x%08lx,%p (%s)),stub!\n", FIXME("(%p,0x%08lx,%p (%s)),stub!\n",
KeyHandle, DesiredAccess, ObjectAttributes,debugstr_w(ObjectAttributes->ObjectName->Buffer)); KeyHandle, DesiredAccess, ObjectAttributes,debugstr_w(ObjectAttributes->ObjectName->Buffer));
return 0; return 0;
} }
@ -163,7 +163,7 @@ NTSTATUS WINAPI NtQueryKey(
ULONG Length, ULONG Length,
PULONG ResultLength) PULONG ResultLength)
{ {
FIXME(ntdll,"(0x%08x,0x%08x,%p,0x%08lx,%p) stub\n", FIXME("(0x%08x,0x%08x,%p,0x%08lx,%p) stub\n",
KeyHandle, KeyInformationClass, KeyInformation, Length, ResultLength); KeyHandle, KeyInformationClass, KeyInformation, Length, ResultLength);
return 0; return 0;
} }
@ -181,7 +181,7 @@ NTSTATUS WINAPI NtQueryMultipleValueKey(
ULONG Length, ULONG Length,
PULONG ReturnLength) PULONG ReturnLength)
{ {
FIXME(ntdll,"(0x%08x,%p,0x%08lx,%p,0x%08lx,%p) stub!\n", FIXME("(0x%08x,%p,0x%08lx,%p,0x%08lx,%p) stub!\n",
KeyHandle, ListOfValuesToQuery, NumberOfItems, MultipleValueInformation, KeyHandle, ListOfValuesToQuery, NumberOfItems, MultipleValueInformation,
Length,ReturnLength); Length,ReturnLength);
return 0; return 0;
@ -199,7 +199,7 @@ NTSTATUS WINAPI NtQueryValueKey(
ULONG Length, ULONG Length,
PULONG ResultLength) PULONG ResultLength)
{ {
FIXME(ntdll,"(0x%08x,%p,0x%08x,%p,0x%08lx,%p) stub\n", FIXME("(0x%08x,%p,0x%08x,%p,0x%08lx,%p) stub\n",
KeyHandle, ValueName, KeyValueInformationClass, KeyValueInformation, Length, ResultLength); KeyHandle, ValueName, KeyValueInformationClass, KeyValueInformation, Length, ResultLength);
return 0; return 0;
} }
@ -213,7 +213,7 @@ NTSTATUS WINAPI NtReplaceKey(
IN HANDLE Key, IN HANDLE Key,
IN POBJECT_ATTRIBUTES ReplacedObjectAttributes) IN POBJECT_ATTRIBUTES ReplacedObjectAttributes)
{ {
FIXME(ntdll,"(%p(%s),0x%08x,%p (%s)),stub!\n", FIXME("(%p(%s),0x%08x,%p (%s)),stub!\n",
ObjectAttributes,debugstr_w(ObjectAttributes->ObjectName->Buffer),Key, ObjectAttributes,debugstr_w(ObjectAttributes->ObjectName->Buffer),Key,
ReplacedObjectAttributes,debugstr_w(ReplacedObjectAttributes->ObjectName->Buffer)); ReplacedObjectAttributes,debugstr_w(ReplacedObjectAttributes->ObjectName->Buffer));
return 0; return 0;
@ -228,7 +228,7 @@ NTSTATUS WINAPI NtRestoreKey(
HANDLE FileHandle, HANDLE FileHandle,
ULONG RestoreFlags) ULONG RestoreFlags)
{ {
FIXME(ntdll,"(0x%08x,0x%08x,0x%08lx) stub\n", FIXME("(0x%08x,0x%08x,0x%08lx) stub\n",
KeyHandle, FileHandle, RestoreFlags); KeyHandle, FileHandle, RestoreFlags);
return 0; return 0;
@ -241,7 +241,7 @@ NTSTATUS WINAPI NtSaveKey(
IN HANDLE KeyHandle, IN HANDLE KeyHandle,
IN HANDLE FileHandle) IN HANDLE FileHandle)
{ {
FIXME(ntdll,"(0x%08x,0x%08x) stub\n", FIXME("(0x%08x,0x%08x) stub\n",
KeyHandle, FileHandle); KeyHandle, FileHandle);
return 0; return 0;
} }
@ -255,7 +255,7 @@ NTSTATUS WINAPI NtSetInformationKey(
IN PVOID KeyInformation, IN PVOID KeyInformation,
IN ULONG KeyInformationLength) IN ULONG KeyInformationLength)
{ {
FIXME(ntdll,"(0x%08x,0x%08x,%p,0x%08lx) stub\n", FIXME("(0x%08x,0x%08x,%p,0x%08lx) stub\n",
KeyHandle, KeyInformationClass, KeyInformation, KeyInformationLength); KeyHandle, KeyInformationClass, KeyInformation, KeyInformationLength);
return 0; return 0;
} }
@ -271,7 +271,7 @@ NTSTATUS WINAPI NtSetValueKey(
PVOID Data, PVOID Data,
ULONG DataSize) ULONG DataSize)
{ {
FIXME(ntdll,"(0x%08x,%p(%s), 0x%08lx, 0x%08lx, %p, 0x%08lx) stub!\n", FIXME("(0x%08x,%p(%s), 0x%08lx, 0x%08lx, %p, 0x%08lx) stub!\n",
KeyHandle, ValueName,debugstr_w(ValueName->Buffer), TitleIndex, Type, Data, DataSize); KeyHandle, ValueName,debugstr_w(ValueName->Buffer), TitleIndex, Type, Data, DataSize);
return 1; return 1;
@ -284,7 +284,7 @@ NTSTATUS WINAPI NtSetValueKey(
NTSTATUS WINAPI NtUnloadKey( NTSTATUS WINAPI NtUnloadKey(
IN HANDLE KeyHandle) IN HANDLE KeyHandle)
{ {
FIXME(ntdll,"(0x%08x) stub\n", FIXME("(0x%08x) stub\n",
KeyHandle); KeyHandle);
return 0; return 0;
} }

View File

@ -10,7 +10,7 @@
#include <stdlib.h> #include <stdlib.h>
#include <string.h> #include <string.h>
#include "heap.h" #include "heap.h"
#include "debug.h" #include "debugtools.h"
#include "winuser.h" #include "winuser.h"
#include "winerror.h" #include "winerror.h"
#include "stackframe.h" #include "stackframe.h"
@ -56,7 +56,7 @@ void WINAPI RtlDeleteResource(LPRTL_RWLOCK rwl)
{ {
EnterCriticalSection( &rwl->rtlCS ); EnterCriticalSection( &rwl->rtlCS );
if( rwl->iNumberActive || rwl->uExclusiveWaiters || rwl->uSharedWaiters ) if( rwl->iNumberActive || rwl->uExclusiveWaiters || rwl->uSharedWaiters )
MSG("Deleting active MRSW lock (%p), expect failure\n", rwl ); MESSAGE("Deleting active MRSW lock (%p), expect failure\n", rwl );
rwl->hOwningThreadId = 0; rwl->hOwningThreadId = 0;
rwl->uExclusiveWaiters = rwl->uSharedWaiters = 0; rwl->uExclusiveWaiters = rwl->uSharedWaiters = 0;
rwl->iNumberActive = 0; rwl->iNumberActive = 0;
@ -203,10 +203,10 @@ void WINAPI RtlDumpResource(LPRTL_RWLOCK rwl)
{ {
if( rwl ) if( rwl )
{ {
MSG("RtlDumpResource(%p):\n\tactive count = %i\n\twaiting readers = %i\n\twaiting writers = %i\n", MESSAGE("RtlDumpResource(%p):\n\tactive count = %i\n\twaiting readers = %i\n\twaiting writers = %i\n",
rwl, rwl->iNumberActive, rwl->uSharedWaiters, rwl->uExclusiveWaiters ); rwl, rwl->iNumberActive, rwl->uSharedWaiters, rwl->uExclusiveWaiters );
if( rwl->iNumberActive ) if( rwl->iNumberActive )
MSG("\towner thread = %08x\n", rwl->hOwningThreadId ); MESSAGE("\towner thread = %08x\n", rwl->hOwningThreadId );
} }
} }
@ -225,7 +225,7 @@ HANDLE WINAPI RtlCreateHeap(
PVOID Unknown, PVOID Unknown,
PRTL_HEAP_DEFINITION Definition) PRTL_HEAP_DEFINITION Definition)
{ {
FIXME (ntdll,"(0x%08lx, %p, 0x%08lx, 0x%08lx, %p, %p) semi-stub\n", FIXME("(0x%08lx, %p, 0x%08lx, 0x%08lx, %p, %p) semi-stub\n",
Flags, BaseAddress, SizeToReserve, SizeToCommit, Unknown, Definition); Flags, BaseAddress, SizeToReserve, SizeToCommit, Unknown, Definition);
return HeapCreate ( Flags, SizeToCommit, SizeToReserve); return HeapCreate ( Flags, SizeToCommit, SizeToReserve);
@ -239,7 +239,7 @@ PVOID WINAPI RtlAllocateHeap(
ULONG Flags, ULONG Flags,
ULONG Size) ULONG Size)
{ {
FIXME(ntdll,"(0x%08x, 0x%08lx, 0x%08lx) semi stub\n", FIXME("(0x%08x, 0x%08lx, 0x%08lx) semi stub\n",
Heap, Flags, Size); Heap, Flags, Size);
return HeapAlloc(Heap, Flags, Size); return HeapAlloc(Heap, Flags, Size);
} }
@ -252,7 +252,7 @@ BOOLEAN WINAPI RtlFreeHeap(
ULONG Flags, ULONG Flags,
PVOID Address) PVOID Address)
{ {
FIXME(ntdll,"(0x%08x, 0x%08lx, %p) semi stub\n", FIXME("(0x%08x, 0x%08lx, %p) semi stub\n",
Heap, Flags, Address); Heap, Flags, Address);
return HeapFree(Heap, Flags, Address); return HeapFree(Heap, Flags, Address);
} }
@ -265,7 +265,7 @@ BOOLEAN WINAPI RtlFreeHeap(
BOOLEAN WINAPI RtlDestroyHeap( BOOLEAN WINAPI RtlDestroyHeap(
HANDLE Heap) HANDLE Heap)
{ {
FIXME(ntdll,"(0x%08x) semi stub\n", Heap); FIXME("(0x%08x) semi stub\n", Heap);
return HeapDestroy(Heap); return HeapDestroy(Heap);
} }
@ -280,7 +280,7 @@ void __cdecl DbgPrint(LPCSTR fmt,LPVOID args) {
char buf[512]; char buf[512];
wvsprintfA(buf,fmt,&args); wvsprintfA(buf,fmt,&args);
MSG("DbgPrint says: %s",buf); MESSAGE("DbgPrint says: %s",buf);
/* hmm, raise exception? */ /* hmm, raise exception? */
} }
@ -288,7 +288,7 @@ void __cdecl DbgPrint(LPCSTR fmt,LPVOID args) {
* RtlAcquirePebLock [NTDLL] * RtlAcquirePebLock [NTDLL]
*/ */
VOID WINAPI RtlAcquirePebLock(void) { VOID WINAPI RtlAcquirePebLock(void) {
FIXME(ntdll,"()\n"); FIXME("()\n");
/* enter critical section ? */ /* enter critical section ? */
} }
@ -296,7 +296,7 @@ VOID WINAPI RtlAcquirePebLock(void) {
* RtlReleasePebLock [NTDLL] * RtlReleasePebLock [NTDLL]
*/ */
VOID WINAPI RtlReleasePebLock(void) { VOID WINAPI RtlReleasePebLock(void) {
FIXME(ntdll,"()\n"); FIXME("()\n");
/* leave critical section ? */ /* leave critical section ? */
} }
@ -304,14 +304,14 @@ VOID WINAPI RtlReleasePebLock(void) {
* RtlIntegerToChar [NTDLL] * RtlIntegerToChar [NTDLL]
*/ */
DWORD WINAPI RtlIntegerToChar(DWORD x1,DWORD x2,DWORD x3,DWORD x4) { DWORD WINAPI RtlIntegerToChar(DWORD x1,DWORD x2,DWORD x3,DWORD x4) {
FIXME(ntdll,"(0x%08lx,0x%08lx,0x%08lx,0x%08lx),stub!\n",x1,x2,x3,x4); FIXME("(0x%08lx,0x%08lx,0x%08lx,0x%08lx),stub!\n",x1,x2,x3,x4);
return 0; return 0;
} }
/****************************************************************************** /******************************************************************************
* RtlSetEnvironmentVariable [NTDLL] * RtlSetEnvironmentVariable [NTDLL]
*/ */
DWORD WINAPI RtlSetEnvironmentVariable(DWORD x1,PUNICODE_STRING key,PUNICODE_STRING val) { DWORD WINAPI RtlSetEnvironmentVariable(DWORD x1,PUNICODE_STRING key,PUNICODE_STRING val) {
FIXME(ntdll,"(0x%08lx,%s,%s),stub!\n",x1,debugstr_w(key->Buffer),debugstr_w(val->Buffer)); FIXME("(0x%08lx,%s,%s),stub!\n",x1,debugstr_w(key->Buffer),debugstr_w(val->Buffer));
return 0; return 0;
} }
@ -319,7 +319,7 @@ DWORD WINAPI RtlSetEnvironmentVariable(DWORD x1,PUNICODE_STRING key,PUNICODE_STR
* RtlNewSecurityObject [NTDLL] * RtlNewSecurityObject [NTDLL]
*/ */
DWORD WINAPI RtlNewSecurityObject(DWORD x1,DWORD x2,DWORD x3,DWORD x4,DWORD x5,DWORD x6) { DWORD WINAPI RtlNewSecurityObject(DWORD x1,DWORD x2,DWORD x3,DWORD x4,DWORD x5,DWORD x6) {
FIXME(ntdll,"(0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx),stub!\n",x1,x2,x3,x4,x5,x6); FIXME("(0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx),stub!\n",x1,x2,x3,x4,x5,x6);
return 0; return 0;
} }
@ -327,7 +327,7 @@ DWORD WINAPI RtlNewSecurityObject(DWORD x1,DWORD x2,DWORD x3,DWORD x4,DWORD x5,D
* RtlDeleteSecurityObject [NTDLL] * RtlDeleteSecurityObject [NTDLL]
*/ */
DWORD WINAPI RtlDeleteSecurityObject(DWORD x1) { DWORD WINAPI RtlDeleteSecurityObject(DWORD x1) {
FIXME(ntdll,"(0x%08lx),stub!\n",x1); FIXME("(0x%08lx),stub!\n",x1);
return 0; return 0;
} }
@ -336,7 +336,7 @@ DWORD WINAPI RtlDeleteSecurityObject(DWORD x1) {
*/ */
LPVOID WINAPI RtlNormalizeProcessParams(LPVOID x) LPVOID WINAPI RtlNormalizeProcessParams(LPVOID x)
{ {
FIXME(ntdll,"(%p), stub\n",x); FIXME("(%p), stub\n",x);
return x; return x;
} }
@ -345,7 +345,7 @@ LPVOID WINAPI RtlNormalizeProcessParams(LPVOID x)
*/ */
DWORD WINAPI RtlNtStatusToDosError(DWORD error) DWORD WINAPI RtlNtStatusToDosError(DWORD error)
{ {
FIXME(ntdll, "(%lx): map STATUS_ to ERROR_\n",error); FIXME("(%lx): map STATUS_ to ERROR_\n",error);
switch (error) switch (error)
{ case STATUS_SUCCESS: return ERROR_SUCCESS; { case STATUS_SUCCESS: return ERROR_SUCCESS;
case STATUS_INVALID_PARAMETER: return ERROR_BAD_ARGUMENTS; case STATUS_INVALID_PARAMETER: return ERROR_BAD_ARGUMENTS;
@ -355,7 +355,7 @@ DWORD WINAPI RtlNtStatusToDosError(DWORD error)
/* case STATUS_UNKNOWN_REVISION: /* case STATUS_UNKNOWN_REVISION:
case STATUS_BUFFER_OVERFLOW:*/ case STATUS_BUFFER_OVERFLOW:*/
} }
FIXME(ntdll, "unknown status (%lx)\n",error); FIXME("unknown status (%lx)\n",error);
return ERROR_SUCCESS; return ERROR_SUCCESS;
} }
@ -364,7 +364,7 @@ DWORD WINAPI RtlNtStatusToDosError(DWORD error)
*/ */
BOOLEAN WINAPI RtlGetNtProductType(LPDWORD type) BOOLEAN WINAPI RtlGetNtProductType(LPDWORD type)
{ {
FIXME(ntdll, "(%p): stub\n", type); FIXME("(%p): stub\n", type);
*type=3; /* dunno. 1 for client, 3 for server? */ *type=3; /* dunno. 1 for client, 3 for server? */
return 1; return 1;
} }
@ -398,7 +398,7 @@ INT WINAPI RtlExtendedLargeIntegerDivide(
*rest = x1 % divisor; *rest = x1 % divisor;
return x1/divisor; return x1/divisor;
#else #else
FIXME(ntdll,"((%d<<32)+%d,%d,%p), implement this using normal integer arithmetic!\n",dividend.HighPart,dividend.LowPart,divisor,rest); FIXME("((%d<<32)+%d,%d,%p), implement this using normal integer arithmetic!\n",dividend.HighPart,dividend.LowPart,divisor,rest);
return 0; return 0;
#endif #endif
} }
@ -415,7 +415,7 @@ long long WINAPI RtlExtendedIntegerMultiply(
#if SIZEOF_LONG_LONG==8 #if SIZEOF_LONG_LONG==8
return (*(long long*)&factor1) * factor2; return (*(long long*)&factor1) * factor2;
#else #else
FIXME(ntdll,"((%d<<32)+%d,%ld), implement this using normal integer arithmetic!\n",factor1.HighPart,factor1.LowPart,factor2); FIXME("((%d<<32)+%d,%ld), implement this using normal integer arithmetic!\n",factor1.HighPart,factor1.LowPart,factor2);
return 0; return 0;
#endif #endif
} }
@ -425,7 +425,7 @@ long long WINAPI RtlExtendedIntegerMultiply(
*/ */
DWORD WINAPI RtlFormatCurrentUserKeyPath(DWORD x) DWORD WINAPI RtlFormatCurrentUserKeyPath(DWORD x)
{ {
FIXME(ntdll,"(0x%08lx): stub\n",x); FIXME("(0x%08lx): stub\n",x);
return 1; return 1;
} }
@ -454,7 +454,7 @@ BOOLEAN WINAPI RtlDosPathNameToNtPathName_U(
{ {
LPSTR fromA = HEAP_strdupWtoA(GetProcessHeap(),0,from); LPSTR fromA = HEAP_strdupWtoA(GetProcessHeap(),0,from);
FIXME(ntdll,"(%s,%p,%08lx,%08lx)\n",fromA,us,x2,x3); FIXME("(%s,%p,%08lx,%08lx)\n",fromA,us,x2,x3);
if (us) if (us)
RtlInitUnicodeString(us,HEAP_strdupW(GetProcessHeap(),0,from)); RtlInitUnicodeString(us,HEAP_strdupW(GetProcessHeap(),0,from));
return TRUE; return TRUE;
@ -464,7 +464,7 @@ BOOLEAN WINAPI RtlDosPathNameToNtPathName_U(
* RtlCreateEnvironment [NTDLL] * RtlCreateEnvironment [NTDLL]
*/ */
DWORD WINAPI RtlCreateEnvironment(DWORD x1,DWORD x2) { DWORD WINAPI RtlCreateEnvironment(DWORD x1,DWORD x2) {
FIXME(ntdll,"(0x%08lx,0x%08lx),stub!\n",x1,x2); FIXME("(0x%08lx,0x%08lx),stub!\n",x1,x2);
return 0; return 0;
} }
@ -473,7 +473,7 @@ DWORD WINAPI RtlCreateEnvironment(DWORD x1,DWORD x2) {
* RtlDestroyEnvironment [NTDLL] * RtlDestroyEnvironment [NTDLL]
*/ */
DWORD WINAPI RtlDestroyEnvironment(DWORD x) { DWORD WINAPI RtlDestroyEnvironment(DWORD x) {
FIXME(ntdll,"(0x%08lx),stub!\n",x); FIXME("(0x%08lx),stub!\n",x);
return 0; return 0;
} }
@ -481,6 +481,6 @@ DWORD WINAPI RtlDestroyEnvironment(DWORD x) {
* RtlQueryEnvironmentVariable_U [NTDLL] * RtlQueryEnvironmentVariable_U [NTDLL]
*/ */
DWORD WINAPI RtlQueryEnvironmentVariable_U(DWORD x1,PUNICODE_STRING key,PUNICODE_STRING val) { DWORD WINAPI RtlQueryEnvironmentVariable_U(DWORD x1,PUNICODE_STRING key,PUNICODE_STRING val) {
FIXME(ntdll,"(0x%08lx,%s,%p),stub!\n",x1,debugstr_w(key->Buffer),val); FIXME("(0x%08lx,%s,%p),stub!\n",x1,debugstr_w(key->Buffer),val);
return 0; return 0;
} }

View File

@ -15,7 +15,7 @@
#include "wine/winestring.h" #include "wine/winestring.h"
#include "heap.h" #include "heap.h"
#include "winnls.h" #include "winnls.h"
#include "debug.h" #include "debugtools.h"
#include "ntddk.h" #include "ntddk.h"
@ -138,7 +138,7 @@ VOID WINAPI RtlInitString(PSTRING target,LPCSTR source)
*/ */
VOID WINAPI RtlInitUnicodeString(PUNICODE_STRING target,LPCWSTR source) VOID WINAPI RtlInitUnicodeString(PUNICODE_STRING target,LPCWSTR source)
{ {
TRACE(ntdll,"%p %p(%s)\n", target, source, debugstr_w(source)); TRACE("%p %p(%s)\n", target, source, debugstr_w(source));
target->Length = target->MaximumLength = 0; target->Length = target->MaximumLength = 0;
target->Buffer = (LPWSTR)source; target->Buffer = (LPWSTR)source;
@ -220,7 +220,7 @@ WINAPI RtlUnicodeStringToAnsiString(PANSI_STRING oem,PUNICODE_STRING uni,BOOLEAN
* RtlEqualUnicodeString [NTDLL] * RtlEqualUnicodeString [NTDLL]
*/ */
DWORD WINAPI RtlEqualUnicodeString(PUNICODE_STRING s1,PUNICODE_STRING s2,DWORD x) { DWORD WINAPI RtlEqualUnicodeString(PUNICODE_STRING s1,PUNICODE_STRING s2,DWORD x) {
FIXME(ntdll,"(%s,%s,%ld),stub!\n",debugstr_w(s1->Buffer),debugstr_w(s2->Buffer),x); FIXME("(%s,%s,%ld),stub!\n",debugstr_w(s1->Buffer),debugstr_w(s2->Buffer),x);
return 0; return 0;
if (s1->Length != s2->Length) if (s1->Length != s2->Length)
return 1; return 1;
@ -318,7 +318,7 @@ out:
NTSTATUS WINAPI RtlCompareUnicodeString( NTSTATUS WINAPI RtlCompareUnicodeString(
PUNICODE_STRING String1, PUNICODE_STRING String2, BOOLEAN CaseInSensitive) PUNICODE_STRING String1, PUNICODE_STRING String2, BOOLEAN CaseInSensitive)
{ {
FIXME(ntdll,"(%s,%s,0x%08x),stub!\n",debugstr_w(String1->Buffer),debugstr_w(String1->Buffer),CaseInSensitive); FIXME("(%s,%s,0x%08x),stub!\n",debugstr_w(String1->Buffer),debugstr_w(String1->Buffer),CaseInSensitive);
return 0; return 0;
} }

View File

@ -17,7 +17,7 @@
#include "heap.h" #include "heap.h"
#include "winnls.h" #include "winnls.h"
#include "debugstr.h" #include "debugstr.h"
#include "debug.h" #include "debugtools.h"
#include "winuser.h" #include "winuser.h"
#include "winerror.h" #include "winerror.h"
#include "stackframe.h" #include "stackframe.h"
@ -38,7 +38,7 @@ DEFAULT_DEBUG_CHANNEL(ntdll)
BOOLEAN WINAPI RtlAllocateAndInitializeSid (PSID_IDENTIFIER_AUTHORITY pIdentifierAuthority, BOOLEAN WINAPI RtlAllocateAndInitializeSid (PSID_IDENTIFIER_AUTHORITY pIdentifierAuthority,
DWORD nSubAuthorityCount,DWORD x3,DWORD x4,DWORD x5,DWORD x6,DWORD x7,DWORD x8,DWORD x9,DWORD x10, PSID pSid) DWORD nSubAuthorityCount,DWORD x3,DWORD x4,DWORD x5,DWORD x6,DWORD x7,DWORD x8,DWORD x9,DWORD x10, PSID pSid)
{ {
FIXME(ntdll,"(%p,0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx,%p),stub!\n", FIXME("(%p,0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx,0x%08lx,%p),stub!\n",
pIdentifierAuthority,nSubAuthorityCount,x3,x4,x5,x6,x7,x8,x9,x10,pSid); pIdentifierAuthority,nSubAuthorityCount,x3,x4,x5,x6,x7,x8,x9,x10,pSid);
return 0; return 0;
} }
@ -48,7 +48,7 @@ BOOLEAN WINAPI RtlAllocateAndInitializeSid (PSID_IDENTIFIER_AUTHORITY pIdentifie
*/ */
DWORD WINAPI RtlEqualSid(DWORD x1,DWORD x2) DWORD WINAPI RtlEqualSid(DWORD x1,DWORD x2)
{ {
FIXME(ntdll,"(0x%08lx,0x%08lx),stub!\n", x1,x2); FIXME("(0x%08lx,0x%08lx),stub!\n", x1,x2);
return TRUE; return TRUE;
} }
@ -57,7 +57,7 @@ DWORD WINAPI RtlEqualSid(DWORD x1,DWORD x2)
*/ */
DWORD WINAPI RtlFreeSid(DWORD x1) DWORD WINAPI RtlFreeSid(DWORD x1)
{ {
FIXME(ntdll,"(0x%08lx),stub!\n", x1); FIXME("(0x%08lx),stub!\n", x1);
return TRUE; return TRUE;
} }
@ -74,7 +74,7 @@ DWORD WINAPI RtlLengthRequiredSid(DWORD nrofsubauths)
*/ */
DWORD WINAPI RtlLengthSid(PSID sid) DWORD WINAPI RtlLengthSid(PSID sid)
{ {
TRACE(ntdll,"sid=%p\n",sid); TRACE("sid=%p\n",sid);
if (!sid) if (!sid)
return FALSE; return FALSE;
return sizeof(DWORD)*sid->SubAuthorityCount+sizeof(SID); return sizeof(DWORD)*sid->SubAuthorityCount+sizeof(SID);
@ -197,7 +197,7 @@ NTSTATUS WINAPI RtlGetDaclSecurityDescriptor(
OUT PACL *pDacl, OUT PACL *pDacl,
OUT PBOOLEAN lpbDaclDefaulted) OUT PBOOLEAN lpbDaclDefaulted)
{ {
TRACE(ntdll,"(%p,%p,%p,%p)\n", TRACE("(%p,%p,%p,%p)\n",
pSecurityDescriptor, lpbDaclPresent, *pDacl, lpbDaclDefaulted); pSecurityDescriptor, lpbDaclPresent, *pDacl, lpbDaclDefaulted);
if (pSecurityDescriptor->Revision != SECURITY_DESCRIPTOR_REVISION) if (pSecurityDescriptor->Revision != SECURITY_DESCRIPTOR_REVISION)
@ -258,7 +258,7 @@ NTSTATUS WINAPI RtlGetSaclSecurityDescriptor(
OUT PACL *pSacl, OUT PACL *pSacl,
OUT PBOOLEAN lpbSaclDefaulted) OUT PBOOLEAN lpbSaclDefaulted)
{ {
TRACE(ntdll,"(%p,%p,%p,%p)\n", TRACE("(%p,%p,%p,%p)\n",
pSecurityDescriptor, lpbSaclPresent, *pSacl, lpbSaclDefaulted); pSecurityDescriptor, lpbSaclPresent, *pSacl, lpbSaclDefaulted);
if (pSecurityDescriptor->Revision != SECURITY_DESCRIPTOR_REVISION) if (pSecurityDescriptor->Revision != SECURITY_DESCRIPTOR_REVISION)
@ -473,7 +473,7 @@ NTSTATUS WINAPI RtlAddAce(
*/ */
DWORD WINAPI RtlAddAccessAllowedAce(DWORD x1,DWORD x2,DWORD x3,DWORD x4) DWORD WINAPI RtlAddAccessAllowedAce(DWORD x1,DWORD x2,DWORD x3,DWORD x4)
{ {
FIXME(ntdll,"(0x%08lx,0x%08lx,0x%08lx,0x%08lx),stub!\n",x1,x2,x3,x4); FIXME("(0x%08lx,0x%08lx,0x%08lx,0x%08lx),stub!\n",x1,x2,x3,x4);
return 0; return 0;
} }
@ -482,7 +482,7 @@ DWORD WINAPI RtlAddAccessAllowedAce(DWORD x1,DWORD x2,DWORD x3,DWORD x4)
*/ */
DWORD WINAPI RtlGetAce(PACL pAcl,DWORD dwAceIndex,LPVOID *pAce ) DWORD WINAPI RtlGetAce(PACL pAcl,DWORD dwAceIndex,LPVOID *pAce )
{ {
FIXME(ntdll,"(%p,%ld,%p),stub!\n",pAcl,dwAceIndex,pAce); FIXME("(%p,%ld,%p),stub!\n",pAcl,dwAceIndex,pAce);
return 0; return 0;
} }
@ -495,7 +495,7 @@ DWORD WINAPI RtlGetAce(PACL pAcl,DWORD dwAceIndex,LPVOID *pAce )
*/ */
DWORD WINAPI RtlAdjustPrivilege(DWORD x1,DWORD x2,DWORD x3,DWORD x4) DWORD WINAPI RtlAdjustPrivilege(DWORD x1,DWORD x2,DWORD x3,DWORD x4)
{ {
FIXME(ntdll,"(0x%08lx,0x%08lx,0x%08lx,0x%08lx),stub!\n",x1,x2,x3,x4); FIXME("(0x%08lx,0x%08lx,0x%08lx,0x%08lx),stub!\n",x1,x2,x3,x4);
return 0; return 0;
} }

View File

@ -6,7 +6,7 @@
#include <string.h> #include <string.h>
#include <time.h> #include <time.h>
#include "debugstr.h" #include "debugstr.h"
#include "debug.h" #include "debugtools.h"
#include "ntddk.h" #include "ntddk.h"
@ -26,7 +26,7 @@ NTSTATUS WINAPI NtCreateSemaphore(
IN ULONG InitialCount, IN ULONG InitialCount,
IN ULONG MaximumCount) IN ULONG MaximumCount)
{ {
FIXME(ntdll,"(%p,0x%08lx,%p(%s),0x%08lx,0x%08lx) stub!\n", FIXME("(%p,0x%08lx,%p(%s),0x%08lx,0x%08lx) stub!\n",
SemaphoreHandle, DesiredAccess, ObjectAttributes, SemaphoreHandle, DesiredAccess, ObjectAttributes,
ObjectAttributes ? debugstr_w(ObjectAttributes->ObjectName->Buffer) : NULL, ObjectAttributes ? debugstr_w(ObjectAttributes->ObjectName->Buffer) : NULL,
InitialCount, MaximumCount); InitialCount, MaximumCount);
@ -41,7 +41,7 @@ NTSTATUS WINAPI NtOpenSemaphore(
IN ACCESS_MASK DesiredAcces, IN ACCESS_MASK DesiredAcces,
IN POBJECT_ATTRIBUTES ObjectAttributes) IN POBJECT_ATTRIBUTES ObjectAttributes)
{ {
FIXME(ntdll,"(0x%08x,0x%08lx,%p(%s)) stub!\n", FIXME("(0x%08x,0x%08lx,%p(%s)) stub!\n",
SemaphoreHandle, DesiredAcces, ObjectAttributes, SemaphoreHandle, DesiredAcces, ObjectAttributes,
ObjectAttributes ? debugstr_w(ObjectAttributes->ObjectName->Buffer) : NULL); ObjectAttributes ? debugstr_w(ObjectAttributes->ObjectName->Buffer) : NULL);
return 0; return 0;
@ -57,7 +57,7 @@ NTSTATUS WINAPI NtQuerySemaphore(
ULONG Length, ULONG Length,
PULONG ReturnLength) PULONG ReturnLength)
{ {
FIXME(ntdll,"(0x%08x,%p,%p,0x%08lx,%p) stub!\n", FIXME("(0x%08x,%p,%p,0x%08lx,%p) stub!\n",
SemaphoreHandle, SemaphoreInformationClass, SemaphoreInformation, Length, ReturnLength); SemaphoreHandle, SemaphoreInformationClass, SemaphoreInformation, Length, ReturnLength);
return 0; return 0;
} }
@ -69,7 +69,7 @@ NTSTATUS WINAPI NtReleaseSemaphore(
IN ULONG ReleaseCount, IN ULONG ReleaseCount,
IN PULONG PreviousCount) IN PULONG PreviousCount)
{ {
FIXME(ntdll,"(0x%08x,0x%08lx,%p,) stub!\n", FIXME("(0x%08x,0x%08lx,%p,) stub!\n",
SemaphoreHandle, ReleaseCount, PreviousCount); SemaphoreHandle, ReleaseCount, PreviousCount);
return 0; return 0;
} }
@ -88,7 +88,7 @@ NTSTATUS WINAPI NtCreateEvent(
IN BOOLEAN ManualReset, IN BOOLEAN ManualReset,
IN BOOLEAN InitialState) IN BOOLEAN InitialState)
{ {
FIXME(ntdll,"(%p,0x%08lx,%p(%s),%08x,%08x): empty stub\n", FIXME("(%p,0x%08lx,%p(%s),%08x,%08x): empty stub\n",
EventHandle,DesiredAccess,ObjectAttributes, EventHandle,DesiredAccess,ObjectAttributes,
ObjectAttributes ? debugstr_w(ObjectAttributes->ObjectName->Buffer) : NULL, ObjectAttributes ? debugstr_w(ObjectAttributes->ObjectName->Buffer) : NULL,
ManualReset,InitialState); ManualReset,InitialState);
@ -103,7 +103,7 @@ NTSTATUS WINAPI NtOpenEvent(
IN ACCESS_MASK DesiredAccess, IN ACCESS_MASK DesiredAccess,
IN POBJECT_ATTRIBUTES ObjectAttributes) IN POBJECT_ATTRIBUTES ObjectAttributes)
{ {
FIXME(ntdll,"(%p,0x%08lx,%p(%s)),stub!\n", FIXME("(%p,0x%08lx,%p(%s)),stub!\n",
EventHandle,DesiredAccess,ObjectAttributes, EventHandle,DesiredAccess,ObjectAttributes,
ObjectAttributes ? debugstr_w(ObjectAttributes->ObjectName->Buffer) : NULL); ObjectAttributes ? debugstr_w(ObjectAttributes->ObjectName->Buffer) : NULL);
return 0; return 0;
@ -116,7 +116,7 @@ NTSTATUS WINAPI NtSetEvent(
IN HANDLE EventHandle, IN HANDLE EventHandle,
PULONG NumberOfThreadsReleased) PULONG NumberOfThreadsReleased)
{ {
FIXME(ntdll,"(0x%08x,%p)\n", FIXME("(0x%08x,%p)\n",
EventHandle, NumberOfThreadsReleased); EventHandle, NumberOfThreadsReleased);
return 0; return 0;
} }

View File

@ -10,7 +10,7 @@
#include <string.h> #include <string.h>
#include "ntddk.h" #include "ntddk.h"
#include "debug.h" #include "debugtools.h"
#include "file.h" #include "file.h"
DEFAULT_DEBUG_CHANNEL(ntdll) DEFAULT_DEBUG_CHANNEL(ntdll)
@ -174,7 +174,7 @@ VOID WINAPI RtlSystemTimeToLocalTime(
IN PLARGE_INTEGER SystemTime, IN PLARGE_INTEGER SystemTime,
OUT PLARGE_INTEGER LocalTime) OUT PLARGE_INTEGER LocalTime)
{ {
FIXME(ntdll,"(%p, %p),stub!\n",SystemTime,LocalTime); FIXME("(%p, %p),stub!\n",SystemTime,LocalTime);
memcpy (LocalTime, SystemTime, sizeof (PLARGE_INTEGER)); memcpy (LocalTime, SystemTime, sizeof (PLARGE_INTEGER));
} }
@ -209,5 +209,5 @@ VOID WINAPI RtlTimeToElapsedTimeFields(
PLARGE_INTEGER liTime, PLARGE_INTEGER liTime,
PTIME_FIELDS TimeFields) PTIME_FIELDS TimeFields)
{ {
FIXME(ntdll,"(%p,%p): stub\n",liTime,TimeFields); FIXME("(%p,%p): stub\n",liTime,TimeFields);
} }

View File

@ -21,7 +21,7 @@
#include "ldt.h" #include "ldt.h"
#include "stackframe.h" #include "stackframe.h"
#include "user.h" #include "user.h"
#include "debug.h" #include "debugtools.h"
#ifdef CONFIG_IPC #ifdef CONFIG_IPC
#include "dde_atom.h" #include "dde_atom.h"
@ -164,7 +164,7 @@ static WORD ATOM_Hash(
) { ) {
WORD i, hash = 0; WORD i, hash = 0;
TRACE(atom,"%x, %s, %x\n", entries, str, len); TRACE("%x, %s, %x\n", entries, str, len);
for (i = 0; i < len; i++) hash ^= toupper(str[i]) + i; for (i = 0; i < len; i++) hash ^= toupper(str[i]) + i;
return hash % entries; return hash % entries;
@ -181,7 +181,7 @@ static BOOL ATOM_IsIntAtom(LPCSTR atomstr,WORD *atomid) {
return FALSE; return FALSE;
*atomid=strtol(atomstr+1,&xend,10); *atomid=strtol(atomstr+1,&xend,10);
if (*xend) { if (*xend) {
FIXME(atom,"found atom named '%s'\n",atomstr); FIXME("found atom named '%s'\n",atomstr);
return FALSE; return FALSE;
} }
return TRUE; return TRUE;
@ -211,7 +211,7 @@ static ATOM ATOM_AddAtom(
int len, ae_len; int len, ae_len;
WORD iatom; WORD iatom;
TRACE(atom,"0x%x, %s\n", selector, str); TRACE("0x%x, %s\n", selector, str);
if (ATOM_IsIntAtom(str,&iatom)) if (ATOM_IsIntAtom(str,&iatom))
return iatom; return iatom;
@ -226,7 +226,7 @@ static ATOM ATOM_AddAtom(
(!lstrncmpiA( entryPtr->str, str, len ))) (!lstrncmpiA( entryPtr->str, str, len )))
{ {
entryPtr->refCount++; entryPtr->refCount++;
TRACE(atom,"-- existing 0x%x\n", entry); TRACE("-- existing 0x%x\n", entry);
return HANDLETOATOM( entry ); return HANDLETOATOM( entry );
} }
entry = entryPtr->next; entry = entryPtr->next;
@ -243,7 +243,7 @@ static ATOM ATOM_AddAtom(
entryPtr->length = len; entryPtr->length = len;
strncpy( entryPtr->str, str, ae_len - sizeof(ATOMENTRY) + 1); /* always use strncpy ('\0's padding) */ strncpy( entryPtr->str, str, ae_len - sizeof(ATOMENTRY) + 1); /* always use strncpy ('\0's padding) */
table->entries[hash] = entry; table->entries[hash] = entry;
TRACE(atom,"-- new 0x%x\n", entry); TRACE("-- new 0x%x\n", entry);
return HANDLETOATOM( entry ); return HANDLETOATOM( entry );
} }
@ -263,7 +263,7 @@ static ATOM ATOM_DeleteAtom(
HANDLE16 entry, *prevEntry; HANDLE16 entry, *prevEntry;
WORD hash; WORD hash;
TRACE(atom,"0x%x, 0x%x\n", selector, atom); TRACE("0x%x, 0x%x\n", selector, atom);
if (atom < MIN_STR_ATOM) return 0; /* Integer atom */ if (atom < MIN_STR_ATOM) return 0; /* Integer atom */
@ -306,7 +306,7 @@ static ATOM ATOM_FindAtom(
HANDLE16 entry; HANDLE16 entry;
int len; int len;
TRACE(atom,"%x, %s\n", selector, str); TRACE("%x, %s\n", selector, str);
if (ATOM_IsIntAtom(str,&iatom)) if (ATOM_IsIntAtom(str,&iatom))
return iatom; return iatom;
if ((len = strlen( str )) > 255) len = 255; if ((len = strlen( str )) > 255) len = 255;
@ -318,12 +318,12 @@ static ATOM ATOM_FindAtom(
ATOMENTRY * entryPtr = ATOM_MakePtr( selector, entry ); ATOMENTRY * entryPtr = ATOM_MakePtr( selector, entry );
if ((entryPtr->length == len) && if ((entryPtr->length == len) &&
(!lstrncmpiA( entryPtr->str, str, len ))) (!lstrncmpiA( entryPtr->str, str, len )))
{ TRACE(atom,"-- found %x\n", entry); { TRACE("-- found %x\n", entry);
return HANDLETOATOM( entry ); return HANDLETOATOM( entry );
} }
entry = entryPtr->next; entry = entryPtr->next;
} }
TRACE(atom,"-- not found\n"); TRACE("-- not found\n");
return 0; return 0;
} }
@ -347,7 +347,7 @@ static UINT ATOM_GetAtomName(
UINT len; UINT len;
char text[8]; char text[8];
TRACE(atom,"%x, %x\n", selector, atom); TRACE("%x, %x\n", selector, atom);
if (!count) return 0; if (!count) return 0;
if (atom < MIN_STR_ATOM) if (atom < MIN_STR_ATOM)

View File

@ -19,7 +19,7 @@
#include "dde_mem.h" #include "dde_mem.h"
#include "stackframe.h" #include "stackframe.h"
#include "module.h" #include "module.h"
#include "debug.h" #include "debugtools.h"
#include "winerror.h" #include "winerror.h"
DEFAULT_DEBUG_CHANNEL(global) DEFAULT_DEBUG_CHANNEL(global)
@ -84,11 +84,11 @@ void debug_handles(void)
for (i = globalArenaSize-1 ; i>=0 ; i--) { for (i = globalArenaSize-1 ; i>=0 ; i--) {
if (pGlobalArena[i].size!=0 && (pGlobalArena[i].handle & 0x8000)){ if (pGlobalArena[i].size!=0 && (pGlobalArena[i].handle & 0x8000)){
printed=1; printed=1;
DUMP("0x%08x, ",pGlobalArena[i].handle); DPRINTF("0x%08x, ",pGlobalArena[i].handle);
} }
} }
if (printed) if (printed)
DUMP("\n"); DPRINTF("\n");
} }
@ -213,7 +213,7 @@ HGLOBAL16 GLOBAL_Alloc( UINT16 flags, DWORD size, HGLOBAL16 hOwner,
HGLOBAL16 handle; HGLOBAL16 handle;
SHMDATA shmdata; SHMDATA shmdata;
TRACE(global, "%ld flags=%04x\n", size, flags ); TRACE("%ld flags=%04x\n", size, flags );
/* If size is 0, create a discarded block */ /* If size is 0, create a discarded block */
@ -331,20 +331,20 @@ HGLOBAL16 WINAPI GlobalReAlloc16(
GLOBALARENA *pArena, *pNewArena; GLOBALARENA *pArena, *pNewArena;
WORD sel = GlobalHandleToSel16( handle ); WORD sel = GlobalHandleToSel16( handle );
TRACE(global, "%04x %ld flags=%04x\n", TRACE("%04x %ld flags=%04x\n",
handle, size, flags ); handle, size, flags );
if (!handle) return 0; if (!handle) return 0;
#ifdef CONFIG_IPC #ifdef CONFIG_IPC
if (flags & GMEM_DDESHARE || is_dde_handle(handle)) if (flags & GMEM_DDESHARE || is_dde_handle(handle))
{ {
FIXME(global, "shared memory reallocating unimplemented\n"); FIXME("shared memory reallocating unimplemented\n");
return 0; return 0;
} }
#endif /* CONFIG_IPC */ #endif /* CONFIG_IPC */
if (!VALID_HANDLE(handle)) { if (!VALID_HANDLE(handle)) {
WARN(global, "Invalid handle 0x%04x!\n", handle); WARN("Invalid handle 0x%04x!\n", handle);
return 0; return 0;
} }
pArena = GET_ARENA_PTR( handle ); pArena = GET_ARENA_PTR( handle );
@ -387,7 +387,7 @@ HGLOBAL16 WINAPI GlobalReAlloc16(
ptr = (void *)pArena->base; ptr = (void *)pArena->base;
oldsize = pArena->size; oldsize = pArena->size;
TRACE(global,"oldsize %08lx\n",oldsize); TRACE("oldsize %08lx\n",oldsize);
if (ptr && (size == oldsize)) return handle; /* Nothing to do */ if (ptr && (size == oldsize)) return handle; /* Nothing to do */
if (((char *)ptr >= DOSMEM_MemoryBase(0)) && if (((char *)ptr >= DOSMEM_MemoryBase(0)) &&
@ -449,12 +449,12 @@ HGLOBAL16 WINAPI GlobalFree16(
void *ptr; void *ptr;
if (!VALID_HANDLE(handle)) { if (!VALID_HANDLE(handle)) {
WARN(global,"Invalid handle 0x%04x passed to GlobalFree16!\n",handle); WARN("Invalid handle 0x%04x passed to GlobalFree16!\n",handle);
return 0; return 0;
} }
ptr = (void *)GET_ARENA_PTR(handle)->base; ptr = (void *)GET_ARENA_PTR(handle)->base;
TRACE(global, "%04x\n", handle ); TRACE("%04x\n", handle );
if (!GLOBAL_FreeBlock( handle )) return handle; /* failed */ if (!GLOBAL_FreeBlock( handle )) return handle; /* failed */
#ifdef CONFIG_IPC #ifdef CONFIG_IPC
if (is_dde_handle(handle)) return DDE_GlobalFree(handle); if (is_dde_handle(handle)) return DDE_GlobalFree(handle);
@ -471,7 +471,7 @@ HGLOBAL16 WINAPI GlobalFree16(
*/ */
SEGPTR WINAPI WIN16_GlobalLock16( HGLOBAL16 handle ) SEGPTR WINAPI WIN16_GlobalLock16( HGLOBAL16 handle )
{ {
TRACE(global, "(%04x) -> %08lx\n", TRACE("(%04x) -> %08lx\n",
handle, MAKELONG( 0, GlobalHandleToSel16(handle)) ); handle, MAKELONG( 0, GlobalHandleToSel16(handle)) );
if (handle) if (handle)
{ {
@ -483,7 +483,7 @@ SEGPTR WINAPI WIN16_GlobalLock16( HGLOBAL16 handle )
#endif /* CONFIG_IPC */ #endif /* CONFIG_IPC */
if (!VALID_HANDLE(handle)) { if (!VALID_HANDLE(handle)) {
WARN(global,"Invalid handle 0x%04x passed to WIN16_GlobalLock16!\n",handle); WARN("Invalid handle 0x%04x passed to WIN16_GlobalLock16!\n",handle);
return (SEGPTR)0; return (SEGPTR)0;
} }
if (!GET_ARENA_PTR(handle)->base) return (SEGPTR)0; if (!GET_ARENA_PTR(handle)->base) return (SEGPTR)0;
@ -532,10 +532,10 @@ BOOL16 WINAPI GlobalUnlock16(
) { ) {
GLOBALARENA *pArena = GET_ARENA_PTR(handle); GLOBALARENA *pArena = GET_ARENA_PTR(handle);
if (!VALID_HANDLE(handle)) { if (!VALID_HANDLE(handle)) {
WARN(global,"Invalid handle 0x%04x passed to GlobalUnlock16!\n",handle); WARN("Invalid handle 0x%04x passed to GlobalUnlock16!\n",handle);
return 0; return 0;
} }
TRACE(global, "%04x\n", handle ); TRACE("%04x\n", handle );
if (pArena->lockCount) pArena->lockCount--; if (pArena->lockCount) pArena->lockCount--;
return pArena->lockCount; return pArena->lockCount;
} }
@ -558,7 +558,7 @@ void WINAPI GlobalChangeLockCount16( CONTEXT *context )
else if ( delta == -1 ) else if ( delta == -1 )
GlobalUnlock16( handle ); GlobalUnlock16( handle );
else else
ERR( global, "(%04X, %d): strange delta value\n", handle, delta ); ERR("(%04X, %d): strange delta value\n", handle, delta );
} }
/*********************************************************************** /***********************************************************************
@ -570,7 +570,7 @@ void WINAPI GlobalChangeLockCount16( CONTEXT *context )
DWORD WINAPI GlobalSize16( DWORD WINAPI GlobalSize16(
HGLOBAL16 handle /* [in] Handle of global memory object */ HGLOBAL16 handle /* [in] Handle of global memory object */
) { ) {
TRACE(global, "%04x\n", handle ); TRACE("%04x\n", handle );
if (!handle) return 0; if (!handle) return 0;
if (!VALID_HANDLE(handle)) if (!VALID_HANDLE(handle))
return 0; return 0;
@ -590,9 +590,9 @@ DWORD WINAPI GlobalSize16(
DWORD WINAPI GlobalHandle16( DWORD WINAPI GlobalHandle16(
WORD sel /* [in] Address of global memory block */ WORD sel /* [in] Address of global memory block */
) { ) {
TRACE(global, "%04x\n", sel ); TRACE("%04x\n", sel );
if (!VALID_HANDLE(sel)) { if (!VALID_HANDLE(sel)) {
WARN(global,"Invalid handle 0x%04x passed to GlobalHandle16!\n",sel); WARN("Invalid handle 0x%04x passed to GlobalHandle16!\n",sel);
return 0; return 0;
} }
return MAKELONG( GET_ARENA_PTR(sel)->handle, GlobalHandleToSel16(sel) ); return MAKELONG( GET_ARENA_PTR(sel)->handle, GlobalHandleToSel16(sel) );
@ -627,9 +627,9 @@ UINT16 WINAPI GlobalFlags16(
) { ) {
GLOBALARENA *pArena; GLOBALARENA *pArena;
TRACE(global, "%04x\n", handle ); TRACE("%04x\n", handle );
if (!VALID_HANDLE(handle)) { if (!VALID_HANDLE(handle)) {
WARN(global,"Invalid handle 0x%04x passed to GlobalFlags16!\n",handle); WARN("Invalid handle 0x%04x passed to GlobalFlags16!\n",handle);
return 0; return 0;
} }
pArena = GET_ARENA_PTR(handle); pArena = GET_ARENA_PTR(handle);
@ -644,10 +644,10 @@ UINT16 WINAPI GlobalFlags16(
*/ */
HGLOBAL16 WINAPI LockSegment16( HGLOBAL16 handle ) HGLOBAL16 WINAPI LockSegment16( HGLOBAL16 handle )
{ {
TRACE(global, "%04x\n", handle ); TRACE("%04x\n", handle );
if (handle == (HGLOBAL16)-1) handle = CURRENT_DS; if (handle == (HGLOBAL16)-1) handle = CURRENT_DS;
if (!VALID_HANDLE(handle)) { if (!VALID_HANDLE(handle)) {
WARN(global,"Invalid handle 0x%04x passed to LockSegment16!\n",handle); WARN("Invalid handle 0x%04x passed to LockSegment16!\n",handle);
return 0; return 0;
} }
GET_ARENA_PTR(handle)->lockCount++; GET_ARENA_PTR(handle)->lockCount++;
@ -660,10 +660,10 @@ HGLOBAL16 WINAPI LockSegment16( HGLOBAL16 handle )
*/ */
void WINAPI UnlockSegment16( HGLOBAL16 handle ) void WINAPI UnlockSegment16( HGLOBAL16 handle )
{ {
TRACE(global, "%04x\n", handle ); TRACE("%04x\n", handle );
if (handle == (HGLOBAL16)-1) handle = CURRENT_DS; if (handle == (HGLOBAL16)-1) handle = CURRENT_DS;
if (!VALID_HANDLE(handle)) { if (!VALID_HANDLE(handle)) {
WARN(global,"Invalid handle 0x%04x passed to UnlockSegment16!\n",handle); WARN("Invalid handle 0x%04x passed to UnlockSegment16!\n",handle);
return; return;
} }
GET_ARENA_PTR(handle)->lockCount--; GET_ARENA_PTR(handle)->lockCount--;
@ -720,7 +720,7 @@ BOOL16 WINAPI GlobalUnWire16( HGLOBAL16 handle )
*/ */
LONG WINAPI SetSwapAreaSize16( WORD size ) LONG WINAPI SetSwapAreaSize16( WORD size )
{ {
FIXME(global, "(%d) - stub!\n", size ); FIXME("(%d) - stub!\n", size );
return MAKELONG( size, 0xffff ); return MAKELONG( size, 0xffff );
} }
@ -730,7 +730,7 @@ LONG WINAPI SetSwapAreaSize16( WORD size )
*/ */
HGLOBAL16 WINAPI GlobalLRUOldest16( HGLOBAL16 handle ) HGLOBAL16 WINAPI GlobalLRUOldest16( HGLOBAL16 handle )
{ {
TRACE(global, "%04x\n", handle ); TRACE("%04x\n", handle );
if (handle == (HGLOBAL16)-1) handle = CURRENT_DS; if (handle == (HGLOBAL16)-1) handle = CURRENT_DS;
return handle; return handle;
} }
@ -741,7 +741,7 @@ HGLOBAL16 WINAPI GlobalLRUOldest16( HGLOBAL16 handle )
*/ */
HGLOBAL16 WINAPI GlobalLRUNewest16( HGLOBAL16 handle ) HGLOBAL16 WINAPI GlobalLRUNewest16( HGLOBAL16 handle )
{ {
TRACE(global, "%04x\n", handle ); TRACE("%04x\n", handle );
if (handle == (HGLOBAL16)-1) handle = CURRENT_DS; if (handle == (HGLOBAL16)-1) handle = CURRENT_DS;
return handle; return handle;
} }
@ -808,9 +808,9 @@ WORD WINAPI GlobalDOSFree16(
*/ */
WORD WINAPI GlobalPageLock16( HGLOBAL16 handle ) WORD WINAPI GlobalPageLock16( HGLOBAL16 handle )
{ {
TRACE(global, "%04x\n", handle ); TRACE("%04x\n", handle );
if (!VALID_HANDLE(handle)) { if (!VALID_HANDLE(handle)) {
WARN(global,"Invalid handle 0x%04x passed to GlobalPageLock!\n",handle); WARN("Invalid handle 0x%04x passed to GlobalPageLock!\n",handle);
return 0; return 0;
} }
return ++(GET_ARENA_PTR(handle)->pageLockCount); return ++(GET_ARENA_PTR(handle)->pageLockCount);
@ -822,9 +822,9 @@ WORD WINAPI GlobalPageLock16( HGLOBAL16 handle )
*/ */
WORD WINAPI GlobalPageUnlock16( HGLOBAL16 handle ) WORD WINAPI GlobalPageUnlock16( HGLOBAL16 handle )
{ {
TRACE(global, "%04x\n", handle ); TRACE("%04x\n", handle );
if (!VALID_HANDLE(handle)) { if (!VALID_HANDLE(handle)) {
WARN(global,"Invalid handle 0x%04x passed to GlobalPageUnlock!\n",handle); WARN("Invalid handle 0x%04x passed to GlobalPageUnlock!\n",handle);
return 0; return 0;
} }
return --(GET_ARENA_PTR(handle)->pageLockCount); return --(GET_ARENA_PTR(handle)->pageLockCount);
@ -836,9 +836,9 @@ WORD WINAPI GlobalPageUnlock16( HGLOBAL16 handle )
*/ */
WORD WINAPI GlobalFix16( HGLOBAL16 handle ) WORD WINAPI GlobalFix16( HGLOBAL16 handle )
{ {
TRACE(global, "%04x\n", handle ); TRACE("%04x\n", handle );
if (!VALID_HANDLE(handle)) { if (!VALID_HANDLE(handle)) {
WARN(global,"Invalid handle 0x%04x passed to GlobalFix16!\n",handle); WARN("Invalid handle 0x%04x passed to GlobalFix16!\n",handle);
return 0; return 0;
} }
GET_ARENA_PTR(handle)->lockCount++; GET_ARENA_PTR(handle)->lockCount++;
@ -852,9 +852,9 @@ WORD WINAPI GlobalFix16( HGLOBAL16 handle )
*/ */
void WINAPI GlobalUnfix16( HGLOBAL16 handle ) void WINAPI GlobalUnfix16( HGLOBAL16 handle )
{ {
TRACE(global, "%04x\n", handle ); TRACE("%04x\n", handle );
if (!VALID_HANDLE(handle)) { if (!VALID_HANDLE(handle)) {
WARN(global,"Invalid handle 0x%04x passed to GlobalUnfix16!\n",handle); WARN("Invalid handle 0x%04x passed to GlobalUnfix16!\n",handle);
return; return;
} }
GET_ARENA_PTR(handle)->lockCount--; GET_ARENA_PTR(handle)->lockCount--;
@ -867,7 +867,7 @@ void WINAPI GlobalUnfix16( HGLOBAL16 handle )
void WINAPI FarSetOwner16( HGLOBAL16 handle, HANDLE16 hOwner ) void WINAPI FarSetOwner16( HGLOBAL16 handle, HANDLE16 hOwner )
{ {
if (!VALID_HANDLE(handle)) { if (!VALID_HANDLE(handle)) {
WARN(global,"Invalid handle 0x%04x passed to FarSetOwner!\n",handle); WARN("Invalid handle 0x%04x passed to FarSetOwner!\n",handle);
return; return;
} }
GET_ARENA_PTR(handle)->hOwner = hOwner; GET_ARENA_PTR(handle)->hOwner = hOwner;
@ -880,7 +880,7 @@ void WINAPI FarSetOwner16( HGLOBAL16 handle, HANDLE16 hOwner )
HANDLE16 WINAPI FarGetOwner16( HGLOBAL16 handle ) HANDLE16 WINAPI FarGetOwner16( HGLOBAL16 handle )
{ {
if (!VALID_HANDLE(handle)) { if (!VALID_HANDLE(handle)) {
WARN(global,"Invalid handle 0x%04x passed to FarGetOwner!\n",handle); WARN("Invalid handle 0x%04x passed to FarGetOwner!\n",handle);
return 0; return 0;
} }
return GET_ARENA_PTR(handle)->hOwner; return GET_ARENA_PTR(handle)->hOwner;
@ -897,12 +897,12 @@ WORD WINAPI GlobalHandleToSel16( HGLOBAL16 handle )
if (is_dde_handle(handle)) return DDE_GlobalHandleToSel(handle); if (is_dde_handle(handle)) return DDE_GlobalHandleToSel(handle);
#endif #endif
if (!VALID_HANDLE(handle)) { if (!VALID_HANDLE(handle)) {
WARN(global,"Invalid handle 0x%04x passed to GlobalHandleToSel!\n",handle); WARN("Invalid handle 0x%04x passed to GlobalHandleToSel!\n",handle);
return 0; return 0;
} }
if (!(handle & 7)) if (!(handle & 7))
{ {
WARN(global, "Program attempted invalid selector conversion\n" ); WARN("Program attempted invalid selector conversion\n" );
return handle - 1; return handle - 1;
} }
return handle | 7; return handle | 7;
@ -1141,7 +1141,7 @@ LPVOID WINAPI GlobalLock(
} }
else else
{ {
WARN(global, "invalid handle\n"); WARN("invalid handle\n");
palloc=(LPVOID) NULL; palloc=(LPVOID) NULL;
} }
/* HeapUnlock(GetProcessHeap()); */; /* HeapUnlock(GetProcessHeap()); */;
@ -1176,7 +1176,7 @@ BOOL WINAPI GlobalUnlock(
} }
else else
{ {
WARN(global, "invalid handle\n"); WARN("invalid handle\n");
locked=FALSE; locked=FALSE;
} }
/* HeapUnlock(GetProcessHeap()); */ /* HeapUnlock(GetProcessHeap()); */
@ -1244,7 +1244,7 @@ HGLOBAL WINAPI GlobalReAlloc(
*/ */
if (hmem == 0) if (hmem == 0)
{ {
ERR(global, "GlobalReAlloc32 with null handle!\n"); ERR("GlobalReAlloc32 with null handle!\n");
SetLastError( ERROR_NOACCESS ); SetLastError( ERROR_NOACCESS );
return 0; return 0;
} }
@ -1280,7 +1280,7 @@ HGLOBAL WINAPI GlobalReAlloc(
/* reallocate a moveable block */ /* reallocate a moveable block */
pintern=HANDLE_TO_INTERN(hmem); pintern=HANDLE_TO_INTERN(hmem);
if(pintern->LockCount>1) { if(pintern->LockCount>1) {
ERR(global,"handle 0x%08lx is still locked, cannot realloc!\n",(DWORD)hmem); ERR("handle 0x%08lx is still locked, cannot realloc!\n",(DWORD)hmem);
SetLastError(ERROR_INVALID_HANDLE); SetLastError(ERROR_INVALID_HANDLE);
} else if(size!=0) } else if(size!=0)
{ {
@ -1382,7 +1382,7 @@ DWORD WINAPI GlobalSize(
} }
else else
{ {
WARN(global, "invalid handle\n"); WARN("invalid handle\n");
retval=0; retval=0;
} }
/* HeapUnlock(GetProcessHeap()); */ /* HeapUnlock(GetProcessHeap()); */
@ -1462,7 +1462,7 @@ UINT WINAPI GlobalFlags(
} }
else else
{ {
WARN(global,"Invalid handle: %04x", hmem); WARN("Invalid handle: %04x", hmem);
retval=0; retval=0;
} }
/* HeapUnlock(GetProcessHeap()); */ /* HeapUnlock(GetProcessHeap()); */

View File

@ -17,7 +17,7 @@
#include "winnt.h" #include "winnt.h"
#include "heap.h" #include "heap.h"
#include "toolhelp.h" #include "toolhelp.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(heap) DEFAULT_DEBUG_CHANNEL(heap)
@ -118,19 +118,19 @@ void HEAP_Dump( HEAP *heap )
SUBHEAP *subheap; SUBHEAP *subheap;
char *ptr; char *ptr;
DUMP( "Heap: %08lx\n", (DWORD)heap ); DPRINTF( "Heap: %08lx\n", (DWORD)heap );
DUMP( "Next: %08lx Sub-heaps: %08lx", DPRINTF( "Next: %08lx Sub-heaps: %08lx",
(DWORD)heap->next, (DWORD)&heap->subheap ); (DWORD)heap->next, (DWORD)&heap->subheap );
subheap = &heap->subheap; subheap = &heap->subheap;
while (subheap->next) while (subheap->next)
{ {
DUMP( " -> %08lx", (DWORD)subheap->next ); DPRINTF( " -> %08lx", (DWORD)subheap->next );
subheap = subheap->next; subheap = subheap->next;
} }
DUMP( "\nFree lists:\n Block Stat Size Id\n" ); DPRINTF( "\nFree lists:\n Block Stat Size Id\n" );
for (i = 0; i < HEAP_NB_FREE_LISTS; i++) for (i = 0; i < HEAP_NB_FREE_LISTS; i++)
DUMP( "%08lx free %08lx %04x prev=%08lx next=%08lx\n", DPRINTF( "%08lx free %08lx %04x prev=%08lx next=%08lx\n",
(DWORD)&heap->freeList[i].arena, heap->freeList[i].arena.size, (DWORD)&heap->freeList[i].arena, heap->freeList[i].arena.size,
heap->freeList[i].arena.threadId, heap->freeList[i].arena.threadId,
(DWORD)heap->freeList[i].arena.prev, (DWORD)heap->freeList[i].arena.prev,
@ -140,17 +140,17 @@ void HEAP_Dump( HEAP *heap )
while (subheap) while (subheap)
{ {
DWORD freeSize = 0, usedSize = 0, arenaSize = subheap->headerSize; DWORD freeSize = 0, usedSize = 0, arenaSize = subheap->headerSize;
DUMP( "\n\nSub-heap %08lx: size=%08lx committed=%08lx\n", DPRINTF( "\n\nSub-heap %08lx: size=%08lx committed=%08lx\n",
(DWORD)subheap, subheap->size, subheap->commitSize ); (DWORD)subheap, subheap->size, subheap->commitSize );
DUMP( "\n Block Stat Size Id\n" ); DPRINTF( "\n Block Stat Size Id\n" );
ptr = (char*)subheap + subheap->headerSize; ptr = (char*)subheap + subheap->headerSize;
while (ptr < (char *)subheap + subheap->size) while (ptr < (char *)subheap + subheap->size)
{ {
if (*(DWORD *)ptr & ARENA_FLAG_FREE) if (*(DWORD *)ptr & ARENA_FLAG_FREE)
{ {
ARENA_FREE *pArena = (ARENA_FREE *)ptr; ARENA_FREE *pArena = (ARENA_FREE *)ptr;
DUMP( "%08lx free %08lx %04x prev=%08lx next=%08lx\n", DPRINTF( "%08lx free %08lx %04x prev=%08lx next=%08lx\n",
(DWORD)pArena, pArena->size & ARENA_SIZE_MASK, (DWORD)pArena, pArena->size & ARENA_SIZE_MASK,
pArena->threadId, (DWORD)pArena->prev, pArena->threadId, (DWORD)pArena->prev,
(DWORD)pArena->next); (DWORD)pArena->next);
@ -161,7 +161,7 @@ void HEAP_Dump( HEAP *heap )
else if (*(DWORD *)ptr & ARENA_FLAG_PREV_FREE) else if (*(DWORD *)ptr & ARENA_FLAG_PREV_FREE)
{ {
ARENA_INUSE *pArena = (ARENA_INUSE *)ptr; ARENA_INUSE *pArena = (ARENA_INUSE *)ptr;
DUMP( "%08lx Used %08lx %04x back=%08lx EIP=%p\n", DPRINTF( "%08lx Used %08lx %04x back=%08lx EIP=%p\n",
(DWORD)pArena, pArena->size & ARENA_SIZE_MASK, (DWORD)pArena, pArena->size & ARENA_SIZE_MASK,
pArena->threadId, *((DWORD *)pArena - 1), pArena->threadId, *((DWORD *)pArena - 1),
pArena->callerEIP ); pArena->callerEIP );
@ -172,7 +172,7 @@ void HEAP_Dump( HEAP *heap )
else else
{ {
ARENA_INUSE *pArena = (ARENA_INUSE *)ptr; ARENA_INUSE *pArena = (ARENA_INUSE *)ptr;
DUMP( "%08lx used %08lx %04x EIP=%p\n", DPRINTF( "%08lx used %08lx %04x EIP=%p\n",
(DWORD)pArena, pArena->size & ARENA_SIZE_MASK, (DWORD)pArena, pArena->size & ARENA_SIZE_MASK,
pArena->threadId, pArena->callerEIP ); pArena->threadId, pArena->callerEIP );
ptr += sizeof(*pArena) + (pArena->size & ARENA_SIZE_MASK); ptr += sizeof(*pArena) + (pArena->size & ARENA_SIZE_MASK);
@ -180,7 +180,7 @@ void HEAP_Dump( HEAP *heap )
usedSize += pArena->size & ARENA_SIZE_MASK; usedSize += pArena->size & ARENA_SIZE_MASK;
} }
} }
DUMP( "\nTotal: Size=%08lx Committed=%08lx Free=%08lx Used=%08lx Arenas=%08lx (%ld%%)\n\n", DPRINTF( "\nTotal: Size=%08lx Committed=%08lx Free=%08lx Used=%08lx Arenas=%08lx (%ld%%)\n\n",
subheap->size, subheap->commitSize, freeSize, usedSize, subheap->size, subheap->commitSize, freeSize, usedSize,
arenaSize, (arenaSize * 100) / subheap->size ); arenaSize, (arenaSize * 100) / subheap->size );
subheap = subheap->next; subheap = subheap->next;
@ -200,7 +200,7 @@ static HEAP *HEAP_GetPtr(
HEAP *heapPtr = (HEAP *)heap; HEAP *heapPtr = (HEAP *)heap;
if (!heapPtr || (heapPtr->magic != HEAP_MAGIC)) if (!heapPtr || (heapPtr->magic != HEAP_MAGIC))
{ {
ERR(heap, "Invalid heap %08x!\n", heap ); ERR("Invalid heap %08x!\n", heap );
SetLastError( ERROR_INVALID_HANDLE ); SetLastError( ERROR_INVALID_HANDLE );
return NULL; return NULL;
} }
@ -270,7 +270,7 @@ static BOOL HEAP_Commit( SUBHEAP *subheap, void *ptr )
size - subheap->commitSize, MEM_COMMIT, size - subheap->commitSize, MEM_COMMIT,
PAGE_EXECUTE_READWRITE)) PAGE_EXECUTE_READWRITE))
{ {
WARN(heap, "Could not commit %08lx bytes at %08lx for heap %08lx\n", WARN("Could not commit %08lx bytes at %08lx for heap %08lx\n",
size - subheap->commitSize, size - subheap->commitSize,
(DWORD)((char *)subheap + subheap->commitSize), (DWORD)((char *)subheap + subheap->commitSize),
(DWORD)subheap->heap ); (DWORD)subheap->heap );
@ -294,7 +294,7 @@ static BOOL HEAP_Decommit( SUBHEAP *subheap, void *ptr )
if (!VirtualFree( (char *)subheap + size, if (!VirtualFree( (char *)subheap + size,
subheap->commitSize - size, MEM_DECOMMIT )) subheap->commitSize - size, MEM_DECOMMIT ))
{ {
WARN(heap, "Could not decommit %08lx bytes at %08lx for heap %08lx\n", WARN("Could not decommit %08lx bytes at %08lx for heap %08lx\n",
subheap->commitSize - size, subheap->commitSize - size,
(DWORD)((char *)subheap + size), (DWORD)((char *)subheap + size),
(DWORD)subheap->heap ); (DWORD)subheap->heap );
@ -454,7 +454,7 @@ static BOOL HEAP_InitSubHeap( HEAP *heap, LPVOID address, DWORD flags,
if (!VirtualAlloc(address, commitSize, MEM_COMMIT, PAGE_EXECUTE_READWRITE)) if (!VirtualAlloc(address, commitSize, MEM_COMMIT, PAGE_EXECUTE_READWRITE))
{ {
WARN(heap, "Could not commit %08lx bytes for sub-heap %08lx\n", WARN("Could not commit %08lx bytes for sub-heap %08lx\n",
commitSize, (DWORD)address ); commitSize, (DWORD)address );
return FALSE; return FALSE;
} }
@ -469,7 +469,7 @@ static BOOL HEAP_InitSubHeap( HEAP *heap, LPVOID address, DWORD flags,
(flags & HEAP_WINE_CODESEG) != 0, FALSE ); (flags & HEAP_WINE_CODESEG) != 0, FALSE );
if (!selector) if (!selector)
{ {
ERR(heap, "Could not allocate selector\n" ); ERR("Could not allocate selector\n" );
return FALSE; return FALSE;
} }
} }
@ -559,7 +559,7 @@ static SUBHEAP *HEAP_CreateSubHeap( HEAP *heap, DWORD flags,
if (!(address = VirtualAlloc( NULL, totalSize, if (!(address = VirtualAlloc( NULL, totalSize,
MEM_RESERVE, PAGE_EXECUTE_READWRITE ))) MEM_RESERVE, PAGE_EXECUTE_READWRITE )))
{ {
WARN(heap, "Could not VirtualAlloc %08lx bytes\n", WARN("Could not VirtualAlloc %08lx bytes\n",
totalSize ); totalSize );
return NULL; return NULL;
} }
@ -613,7 +613,7 @@ static ARENA_FREE *HEAP_FindFreeBlock( HEAP *heap, DWORD size,
if (!(heap->flags & HEAP_GROWABLE)) if (!(heap->flags & HEAP_GROWABLE))
{ {
WARN(heap, "Not enough space in heap %08lx for %08lx bytes\n", WARN("Not enough space in heap %08lx for %08lx bytes\n",
(DWORD)heap, size ); (DWORD)heap, size );
return NULL; return NULL;
} }
@ -622,7 +622,7 @@ static ARENA_FREE *HEAP_FindFreeBlock( HEAP *heap, DWORD size,
MAX( HEAP_DEF_SIZE, size ) ))) MAX( HEAP_DEF_SIZE, size ) )))
return NULL; return NULL;
TRACE(heap, "created new sub-heap %08lx of %08lx bytes for heap %08lx\n", TRACE("created new sub-heap %08lx of %08lx bytes for heap %08lx\n",
(DWORD)subheap, size, (DWORD)heap ); (DWORD)subheap, size, (DWORD)heap );
*ppSubHeap = subheap; *ppSubHeap = subheap;
@ -658,7 +658,7 @@ static BOOL HEAP_ValidateFreeArena( SUBHEAP *subheap, ARENA_FREE *pArena )
/* Check magic number */ /* Check magic number */
if (pArena->magic != ARENA_FREE_MAGIC) if (pArena->magic != ARENA_FREE_MAGIC)
{ {
ERR(heap, "Heap %08lx: invalid free arena magic for %08lx\n", ERR("Heap %08lx: invalid free arena magic for %08lx\n",
(DWORD)subheap->heap, (DWORD)pArena ); (DWORD)subheap->heap, (DWORD)pArena );
return FALSE; return FALSE;
} }
@ -666,20 +666,20 @@ static BOOL HEAP_ValidateFreeArena( SUBHEAP *subheap, ARENA_FREE *pArena )
if (!(pArena->size & ARENA_FLAG_FREE) || if (!(pArena->size & ARENA_FLAG_FREE) ||
(pArena->size & ARENA_FLAG_PREV_FREE)) (pArena->size & ARENA_FLAG_PREV_FREE))
{ {
ERR(heap, "Heap %08lx: bad flags %lx for free arena %08lx\n", ERR("Heap %08lx: bad flags %lx for free arena %08lx\n",
(DWORD)subheap->heap, pArena->size & ~ARENA_SIZE_MASK, (DWORD)pArena ); (DWORD)subheap->heap, pArena->size & ~ARENA_SIZE_MASK, (DWORD)pArena );
} }
/* Check arena size */ /* Check arena size */
if ((char *)(pArena + 1) + (pArena->size & ARENA_SIZE_MASK) > heapEnd) if ((char *)(pArena + 1) + (pArena->size & ARENA_SIZE_MASK) > heapEnd)
{ {
ERR(heap, "Heap %08lx: bad size %08lx for free arena %08lx\n", ERR("Heap %08lx: bad size %08lx for free arena %08lx\n",
(DWORD)subheap->heap, (DWORD)pArena->size & ARENA_SIZE_MASK, (DWORD)pArena ); (DWORD)subheap->heap, (DWORD)pArena->size & ARENA_SIZE_MASK, (DWORD)pArena );
return FALSE; return FALSE;
} }
/* Check that next pointer is valid */ /* Check that next pointer is valid */
if (!HEAP_IsValidArenaPtr( subheap->heap, pArena->next )) if (!HEAP_IsValidArenaPtr( subheap->heap, pArena->next ))
{ {
ERR(heap, "Heap %08lx: bad next ptr %08lx for arena %08lx\n", ERR("Heap %08lx: bad next ptr %08lx for arena %08lx\n",
(DWORD)subheap->heap, (DWORD)pArena->next, (DWORD)pArena ); (DWORD)subheap->heap, (DWORD)pArena->next, (DWORD)pArena );
return FALSE; return FALSE;
} }
@ -687,14 +687,14 @@ static BOOL HEAP_ValidateFreeArena( SUBHEAP *subheap, ARENA_FREE *pArena )
if (!(pArena->next->size & ARENA_FLAG_FREE) || if (!(pArena->next->size & ARENA_FLAG_FREE) ||
(pArena->next->magic != ARENA_FREE_MAGIC)) (pArena->next->magic != ARENA_FREE_MAGIC))
{ {
ERR(heap, "Heap %08lx: next arena %08lx invalid for %08lx\n", ERR("Heap %08lx: next arena %08lx invalid for %08lx\n",
(DWORD)subheap->heap, (DWORD)pArena->next, (DWORD)pArena ); (DWORD)subheap->heap, (DWORD)pArena->next, (DWORD)pArena );
return FALSE; return FALSE;
} }
/* Check that prev pointer is valid */ /* Check that prev pointer is valid */
if (!HEAP_IsValidArenaPtr( subheap->heap, pArena->prev )) if (!HEAP_IsValidArenaPtr( subheap->heap, pArena->prev ))
{ {
ERR(heap, "Heap %08lx: bad prev ptr %08lx for arena %08lx\n", ERR("Heap %08lx: bad prev ptr %08lx for arena %08lx\n",
(DWORD)subheap->heap, (DWORD)pArena->prev, (DWORD)pArena ); (DWORD)subheap->heap, (DWORD)pArena->prev, (DWORD)pArena );
return FALSE; return FALSE;
} }
@ -702,7 +702,7 @@ static BOOL HEAP_ValidateFreeArena( SUBHEAP *subheap, ARENA_FREE *pArena )
if (!(pArena->prev->size & ARENA_FLAG_FREE) || if (!(pArena->prev->size & ARENA_FLAG_FREE) ||
(pArena->prev->magic != ARENA_FREE_MAGIC)) (pArena->prev->magic != ARENA_FREE_MAGIC))
{ {
ERR(heap, "Heap %08lx: prev arena %08lx invalid for %08lx\n", ERR("Heap %08lx: prev arena %08lx invalid for %08lx\n",
(DWORD)subheap->heap, (DWORD)pArena->prev, (DWORD)pArena ); (DWORD)subheap->heap, (DWORD)pArena->prev, (DWORD)pArena );
return FALSE; return FALSE;
} }
@ -712,7 +712,7 @@ static BOOL HEAP_ValidateFreeArena( SUBHEAP *subheap, ARENA_FREE *pArena )
if (!(*(DWORD *)((char *)(pArena + 1) + if (!(*(DWORD *)((char *)(pArena + 1) +
(pArena->size & ARENA_SIZE_MASK)) & ARENA_FLAG_PREV_FREE)) (pArena->size & ARENA_SIZE_MASK)) & ARENA_FLAG_PREV_FREE))
{ {
ERR(heap, "Heap %08lx: free arena %08lx next block has no PREV_FREE flag\n", ERR("Heap %08lx: free arena %08lx next block has no PREV_FREE flag\n",
(DWORD)subheap->heap, (DWORD)pArena ); (DWORD)subheap->heap, (DWORD)pArena );
return FALSE; return FALSE;
} }
@ -720,7 +720,7 @@ static BOOL HEAP_ValidateFreeArena( SUBHEAP *subheap, ARENA_FREE *pArena )
if (*((ARENA_FREE **)((char *)(pArena + 1) + if (*((ARENA_FREE **)((char *)(pArena + 1) +
(pArena->size & ARENA_SIZE_MASK)) - 1) != pArena) (pArena->size & ARENA_SIZE_MASK)) - 1) != pArena)
{ {
ERR(heap, "Heap %08lx: arena %08lx has wrong back ptr %08lx\n", ERR("Heap %08lx: arena %08lx has wrong back ptr %08lx\n",
(DWORD)subheap->heap, (DWORD)pArena, (DWORD)subheap->heap, (DWORD)pArena,
*((DWORD *)((char *)(pArena+1)+ (pArena->size & ARENA_SIZE_MASK)) - 1)); *((DWORD *)((char *)(pArena+1)+ (pArena->size & ARENA_SIZE_MASK)) - 1));
return FALSE; return FALSE;
@ -740,20 +740,20 @@ static BOOL HEAP_ValidateInUseArena( SUBHEAP *subheap, ARENA_INUSE *pArena )
/* Check magic number */ /* Check magic number */
if (pArena->magic != ARENA_INUSE_MAGIC) if (pArena->magic != ARENA_INUSE_MAGIC)
{ {
ERR(heap, "Heap %08lx: invalid in-use arena magic for %08lx\n", ERR("Heap %08lx: invalid in-use arena magic for %08lx\n",
(DWORD)subheap->heap, (DWORD)pArena ); (DWORD)subheap->heap, (DWORD)pArena );
return FALSE; return FALSE;
} }
/* Check size flags */ /* Check size flags */
if (pArena->size & ARENA_FLAG_FREE) if (pArena->size & ARENA_FLAG_FREE)
{ {
ERR(heap, "Heap %08lx: bad flags %lx for in-use arena %08lx\n", ERR("Heap %08lx: bad flags %lx for in-use arena %08lx\n",
(DWORD)subheap->heap, pArena->size & ~ARENA_SIZE_MASK, (DWORD)pArena ); (DWORD)subheap->heap, pArena->size & ~ARENA_SIZE_MASK, (DWORD)pArena );
} }
/* Check arena size */ /* Check arena size */
if ((char *)(pArena + 1) + (pArena->size & ARENA_SIZE_MASK) > heapEnd) if ((char *)(pArena + 1) + (pArena->size & ARENA_SIZE_MASK) > heapEnd)
{ {
ERR(heap, "Heap %08lx: bad size %08lx for in-use arena %08lx\n", ERR("Heap %08lx: bad size %08lx for in-use arena %08lx\n",
(DWORD)subheap->heap, (DWORD)pArena->size & ARENA_SIZE_MASK, (DWORD)pArena ); (DWORD)subheap->heap, (DWORD)pArena->size & ARENA_SIZE_MASK, (DWORD)pArena );
return FALSE; return FALSE;
} }
@ -761,7 +761,7 @@ static BOOL HEAP_ValidateInUseArena( SUBHEAP *subheap, ARENA_INUSE *pArena )
if (((char *)(pArena + 1) + (pArena->size & ARENA_SIZE_MASK) < heapEnd) && if (((char *)(pArena + 1) + (pArena->size & ARENA_SIZE_MASK) < heapEnd) &&
(*(DWORD *)((char *)(pArena + 1) + (pArena->size & ARENA_SIZE_MASK)) & ARENA_FLAG_PREV_FREE)) (*(DWORD *)((char *)(pArena + 1) + (pArena->size & ARENA_SIZE_MASK)) & ARENA_FLAG_PREV_FREE))
{ {
ERR(heap, "Heap %08lx: in-use arena %08lx next block has PREV_FREE flag\n", ERR("Heap %08lx: in-use arena %08lx next block has PREV_FREE flag\n",
(DWORD)subheap->heap, (DWORD)pArena ); (DWORD)subheap->heap, (DWORD)pArena );
return FALSE; return FALSE;
} }
@ -772,7 +772,7 @@ static BOOL HEAP_ValidateInUseArena( SUBHEAP *subheap, ARENA_INUSE *pArena )
/* Check prev pointer */ /* Check prev pointer */
if (!HEAP_IsValidArenaPtr( subheap->heap, pPrev )) if (!HEAP_IsValidArenaPtr( subheap->heap, pPrev ))
{ {
ERR(heap, "Heap %08lx: bad back ptr %08lx for arena %08lx\n", ERR("Heap %08lx: bad back ptr %08lx for arena %08lx\n",
(DWORD)subheap->heap, (DWORD)pPrev, (DWORD)pArena ); (DWORD)subheap->heap, (DWORD)pPrev, (DWORD)pArena );
return FALSE; return FALSE;
} }
@ -780,14 +780,14 @@ static BOOL HEAP_ValidateInUseArena( SUBHEAP *subheap, ARENA_INUSE *pArena )
if (!(pPrev->size & ARENA_FLAG_FREE) || if (!(pPrev->size & ARENA_FLAG_FREE) ||
(pPrev->magic != ARENA_FREE_MAGIC)) (pPrev->magic != ARENA_FREE_MAGIC))
{ {
ERR(heap, "Heap %08lx: prev arena %08lx invalid for in-use %08lx\n", ERR("Heap %08lx: prev arena %08lx invalid for in-use %08lx\n",
(DWORD)subheap->heap, (DWORD)pPrev, (DWORD)pArena ); (DWORD)subheap->heap, (DWORD)pPrev, (DWORD)pArena );
return FALSE; return FALSE;
} }
/* Check that prev arena is really the previous block */ /* Check that prev arena is really the previous block */
if ((char *)(pPrev + 1) + (pPrev->size & ARENA_SIZE_MASK) != (char *)pArena) if ((char *)(pPrev + 1) + (pPrev->size & ARENA_SIZE_MASK) != (char *)pArena)
{ {
ERR(heap, "Heap %08lx: prev arena %08lx is not prev for in-use %08lx\n", ERR("Heap %08lx: prev arena %08lx is not prev for in-use %08lx\n",
(DWORD)subheap->heap, (DWORD)pPrev, (DWORD)pArena ); (DWORD)subheap->heap, (DWORD)pPrev, (DWORD)pArena );
return FALSE; return FALSE;
} }
@ -847,7 +847,7 @@ SEGPTR HEAP_GetSegptr( HANDLE heap, DWORD flags, LPCVOID ptr )
flags |= heapPtr->flags; flags |= heapPtr->flags;
if (!(flags & HEAP_WINE_SEGPTR)) if (!(flags & HEAP_WINE_SEGPTR))
{ {
ERR(heap, "Heap %08x is not a SEGPTR heap\n", ERR("Heap %08x is not a SEGPTR heap\n",
heap ); heap );
return 0; return 0;
} }
@ -857,7 +857,7 @@ SEGPTR HEAP_GetSegptr( HANDLE heap, DWORD flags, LPCVOID ptr )
if (!(subheap = HEAP_FindSubHeap( heapPtr, ptr ))) if (!(subheap = HEAP_FindSubHeap( heapPtr, ptr )))
{ {
ERR(heap, "%p is not inside heap %08x\n", ERR("%p is not inside heap %08x\n",
ptr, heap ); ptr, heap );
if (!(flags & HEAP_NO_SERIALIZE)) HeapUnlock( heap ); if (!(flags & HEAP_NO_SERIALIZE)) HeapUnlock( heap );
return 0; return 0;
@ -912,7 +912,7 @@ BOOL WINAPI HeapDestroy(
HEAP *heapPtr = HEAP_GetPtr( heap ); HEAP *heapPtr = HEAP_GetPtr( heap );
SUBHEAP *subheap; SUBHEAP *subheap;
TRACE(heap, "%08x\n", heap ); TRACE("%08x\n", heap );
if (!heapPtr) return FALSE; if (!heapPtr) return FALSE;
DeleteCriticalSection( &heapPtr->critSection ); DeleteCriticalSection( &heapPtr->critSection );
@ -957,7 +957,7 @@ LPVOID WINAPI HeapAlloc(
if (!(pArena = HEAP_FindFreeBlock( heapPtr, size, &subheap ))) if (!(pArena = HEAP_FindFreeBlock( heapPtr, size, &subheap )))
{ {
TRACE(heap, "(%08x,%08lx,%08lx): returning NULL\n", TRACE("(%08x,%08lx,%08lx): returning NULL\n",
heap, flags, size ); heap, flags, size );
if (!(flags & HEAP_NO_SERIALIZE)) HeapUnlock( heap ); if (!(flags & HEAP_NO_SERIALIZE)) HeapUnlock( heap );
SetLastError( ERROR_COMMITMENT_LIMIT ); SetLastError( ERROR_COMMITMENT_LIMIT );
@ -987,7 +987,7 @@ LPVOID WINAPI HeapAlloc(
if (!(flags & HEAP_NO_SERIALIZE)) HeapUnlock( heap ); if (!(flags & HEAP_NO_SERIALIZE)) HeapUnlock( heap );
TRACE(heap, "(%08x,%08lx,%08lx): returning %08lx\n", TRACE("(%08x,%08lx,%08lx): returning %08lx\n",
heap, flags, size, (DWORD)(pInUse + 1) ); heap, flags, size, (DWORD)(pInUse + 1) );
return (LPVOID)(pInUse + 1); return (LPVOID)(pInUse + 1);
} }
@ -1016,14 +1016,14 @@ BOOL WINAPI HeapFree(
if (!(flags & HEAP_NO_SERIALIZE)) HeapLock( heap ); if (!(flags & HEAP_NO_SERIALIZE)) HeapLock( heap );
if (!ptr) if (!ptr)
{ {
WARN(heap, "(%08x,%08lx,%08lx): asked to free NULL\n", WARN("(%08x,%08lx,%08lx): asked to free NULL\n",
heap, flags, (DWORD)ptr ); heap, flags, (DWORD)ptr );
} }
if (!ptr || !HeapValidate( heap, HEAP_NO_SERIALIZE, ptr )) if (!ptr || !HeapValidate( heap, HEAP_NO_SERIALIZE, ptr ))
{ {
if (!(flags & HEAP_NO_SERIALIZE)) HeapUnlock( heap ); if (!(flags & HEAP_NO_SERIALIZE)) HeapUnlock( heap );
SetLastError( ERROR_INVALID_PARAMETER ); SetLastError( ERROR_INVALID_PARAMETER );
TRACE(heap, "(%08x,%08lx,%08lx): returning FALSE\n", TRACE("(%08x,%08lx,%08lx): returning FALSE\n",
heap, flags, (DWORD)ptr ); heap, flags, (DWORD)ptr );
return FALSE; return FALSE;
} }
@ -1037,7 +1037,7 @@ BOOL WINAPI HeapFree(
if (!(flags & HEAP_NO_SERIALIZE)) HeapUnlock( heap ); if (!(flags & HEAP_NO_SERIALIZE)) HeapUnlock( heap );
/* SetLastError( 0 ); */ /* SetLastError( 0 ); */
TRACE(heap, "(%08x,%08lx,%08lx): returning TRUE\n", TRACE("(%08x,%08lx,%08lx): returning TRUE\n",
heap, flags, (DWORD)ptr ); heap, flags, (DWORD)ptr );
return TRUE; return TRUE;
} }
@ -1076,7 +1076,7 @@ LPVOID WINAPI HeapReAlloc(
{ {
if (!(flags & HEAP_NO_SERIALIZE)) HeapUnlock( heap ); if (!(flags & HEAP_NO_SERIALIZE)) HeapUnlock( heap );
SetLastError( ERROR_INVALID_PARAMETER ); SetLastError( ERROR_INVALID_PARAMETER );
TRACE(heap, "(%08x,%08lx,%08lx,%08lx): returning NULL\n", TRACE("(%08x,%08lx,%08lx,%08lx): returning NULL\n",
heap, flags, (DWORD)ptr, size ); heap, flags, (DWORD)ptr, size );
return NULL; return NULL;
} }
@ -1160,7 +1160,7 @@ LPVOID WINAPI HeapReAlloc(
pArena->callerEIP = GET_EIP(); pArena->callerEIP = GET_EIP();
if (!(flags & HEAP_NO_SERIALIZE)) HeapUnlock( heap ); if (!(flags & HEAP_NO_SERIALIZE)) HeapUnlock( heap );
TRACE(heap, "(%08x,%08lx,%08lx,%08lx): returning %08lx\n", TRACE("(%08x,%08lx,%08lx,%08lx): returning %08lx\n",
heap, flags, (DWORD)ptr, size, (DWORD)(pArena + 1) ); heap, flags, (DWORD)ptr, size, (DWORD)(pArena + 1) );
return (LPVOID)(pArena + 1); return (LPVOID)(pArena + 1);
} }
@ -1242,7 +1242,7 @@ DWORD WINAPI HeapSize(
} }
if (!(flags & HEAP_NO_SERIALIZE)) HeapUnlock( heap ); if (!(flags & HEAP_NO_SERIALIZE)) HeapUnlock( heap );
TRACE(heap, "(%08x,%08lx,%08lx): returning %08lx\n", TRACE("(%08x,%08lx,%08lx): returning %08lx\n",
heap, flags, (DWORD)ptr, ret ); heap, flags, (DWORD)ptr, ret );
return ret; return ret;
} }
@ -1270,7 +1270,7 @@ BOOL WINAPI HeapValidate(
if (!heapPtr || (heapPtr->magic != HEAP_MAGIC)) if (!heapPtr || (heapPtr->magic != HEAP_MAGIC))
{ {
ERR(heap, "Invalid heap %08x!\n", heap ); ERR("Invalid heap %08x!\n", heap );
return FALSE; return FALSE;
} }
@ -1286,7 +1286,7 @@ BOOL WINAPI HeapValidate(
((char *)block < (char *)subheap + subheap->headerSize ((char *)block < (char *)subheap + subheap->headerSize
+ sizeof(ARENA_INUSE))) + sizeof(ARENA_INUSE)))
{ {
ERR(heap, "Heap %08lx: block %08lx is not inside heap\n", ERR("Heap %08lx: block %08lx is not inside heap\n",
(DWORD)heap, (DWORD)block ); (DWORD)heap, (DWORD)block );
ret = FALSE; ret = FALSE;
} else } else
@ -1340,7 +1340,7 @@ BOOL WINAPI HeapWalk(
HANDLE heap, /* [in] Handle to heap to enumerate */ HANDLE heap, /* [in] Handle to heap to enumerate */
LPPROCESS_HEAP_ENTRY *entry /* [out] Pointer to structure of enumeration info */ LPPROCESS_HEAP_ENTRY *entry /* [out] Pointer to structure of enumeration info */
) { ) {
FIXME(heap, "(%08x): stub.\n", heap ); FIXME("(%08x): stub.\n", heap );
return FALSE; return FALSE;
} }
@ -1355,7 +1355,7 @@ LPVOID HEAP_xalloc( HANDLE heap, DWORD flags, DWORD size )
LPVOID p = HeapAlloc( heap, flags, size ); LPVOID p = HeapAlloc( heap, flags, size );
if (!p) if (!p)
{ {
MSG("Virtual memory exhausted.\n" ); MESSAGE("Virtual memory exhausted.\n" );
exit(1); exit(1);
} }
SET_EIP(p); SET_EIP(p);
@ -1373,7 +1373,7 @@ LPVOID HEAP_xrealloc( HANDLE heap, DWORD flags, LPVOID lpMem, DWORD size )
LPVOID p = HeapReAlloc( heap, flags, lpMem, size ); LPVOID p = HeapReAlloc( heap, flags, lpMem, size );
if (!p) if (!p)
{ {
MSG("Virtual memory exhausted.\n" ); MESSAGE("Virtual memory exhausted.\n" );
exit(1); exit(1);
} }
SET_EIP(p); SET_EIP(p);
@ -1701,7 +1701,7 @@ DWORD WINAPI Local32Alloc16( HANDLE heap, DWORD size, INT16 type, DWORD flags )
break; break;
if (page == HTABLE_NPAGES) if (page == HTABLE_NPAGES)
{ {
WARN( heap, "Out of handles!\n" ); WARN("Out of handles!\n" );
HeapFree( header->heap, 0, ptr ); HeapFree( header->heap, 0, ptr );
return 0; return 0;
} }
@ -1712,7 +1712,7 @@ DWORD WINAPI Local32Alloc16( HANDLE heap, DWORD size, INT16 type, DWORD flags )
if ( !VirtualAlloc( (LPBYTE)header + (page << 12), if ( !VirtualAlloc( (LPBYTE)header + (page << 12),
0x1000, MEM_COMMIT, PAGE_READWRITE ) ) 0x1000, MEM_COMMIT, PAGE_READWRITE ) )
{ {
WARN( heap, "Cannot grow handle table!\n" ); WARN("Cannot grow handle table!\n" );
HeapFree( header->heap, 0, ptr ); HeapFree( header->heap, 0, ptr );
return 0; return 0;
} }
@ -1968,7 +1968,7 @@ BOOL16 WINAPI Local32Info16( LOCAL32INFO *pLocal32Info, HGLOBAL16 handle )
*/ */
BOOL16 WINAPI Local32First16( LOCAL32ENTRY *pLocal32Entry, HGLOBAL16 handle ) BOOL16 WINAPI Local32First16( LOCAL32ENTRY *pLocal32Entry, HGLOBAL16 handle )
{ {
FIXME( heap, "(%p, %04X): stub!\n", pLocal32Entry, handle ); FIXME("(%p, %04X): stub!\n", pLocal32Entry, handle );
return FALSE; return FALSE;
} }
@ -1977,7 +1977,7 @@ BOOL16 WINAPI Local32First16( LOCAL32ENTRY *pLocal32Entry, HGLOBAL16 handle )
*/ */
BOOL16 WINAPI Local32Next16( LOCAL32ENTRY *pLocal32Entry ) BOOL16 WINAPI Local32Next16( LOCAL32ENTRY *pLocal32Entry )
{ {
FIXME( heap, "(%p): stub!\n", pLocal32Entry ); FIXME("(%p): stub!\n", pLocal32Entry );
return FALSE; return FALSE;
} }

View File

@ -9,7 +9,7 @@
#include <string.h> #include <string.h>
#include <errno.h> #include <errno.h>
#include "ldt.h" #include "ldt.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(ldt) DEFAULT_DEBUG_CHANNEL(ldt)
@ -148,7 +148,7 @@ int LDT_SetEntry( int entry, const ldt_entry *content )
{ {
int ret = 0; int ret = 0;
TRACE(ldt, "entry=%04x base=%08lx limit=%05lx %s %d-bit " TRACE("entry=%04x base=%08lx limit=%05lx %s %d-bit "
"flags=%c%c%c\n", entry, content->base, content->limit, "flags=%c%c%c\n", entry, content->base, content->limit,
content->limit_in_pages ? "pages" : "bytes", content->limit_in_pages ? "pages" : "bytes",
content->seg_32bit ? 32 : 16, content->seg_32bit ? 32 : 16,
@ -183,7 +183,7 @@ int LDT_SetEntry( int entry, const ldt_entry *content )
{ {
if (ldt_info.base_addr >= 0xc0000000) if (ldt_info.base_addr >= 0xc0000000)
{ {
WARN(ldt, "Invalid base addr %08lx\n", WARN("Invalid base addr %08lx\n",
ldt_info.base_addr ); ldt_info.base_addr );
return -1; return -1;
} }
@ -213,7 +213,7 @@ int LDT_SetEntry( int entry, const ldt_entry *content )
if (ret < 0) if (ret < 0)
{ {
perror("i386_set_ldt"); perror("i386_set_ldt");
MSG("Did you reconfigure the kernel with \"options USER_LDT\"?\n"); MESSAGE("Did you reconfigure the kernel with \"options USER_LDT\"?\n");
exit(1); exit(1);
} }
} }
@ -287,7 +287,7 @@ void LDT_Print( int start, int length )
flags[1] = (ldt_flags_copy[i] & LDT_FLAGS_READONLY) ? '-' : 'w'; flags[1] = (ldt_flags_copy[i] & LDT_FLAGS_READONLY) ? '-' : 'w';
flags[2] = '-'; flags[2] = '-';
} }
MSG("%04x: sel=%04x base=%08lx limit=%08lx %d-bit %c%c%c\n", MESSAGE("%04x: sel=%04x base=%08lx limit=%08lx %d-bit %c%c%c\n",
i, ENTRY_TO_SELECTOR(i), ldt_copy[i].base, ldt_copy[i].limit, i, ENTRY_TO_SELECTOR(i), ldt_copy[i].base, ldt_copy[i].limit,
ldt_flags_copy[i] & LDT_FLAGS_32BIT ? 32 : 16, ldt_flags_copy[i] & LDT_FLAGS_32BIT ? 32 : 16,
flags[0], flags[1], flags[2] ); flags[0], flags[1], flags[2] );

View File

@ -11,7 +11,7 @@
#include "selectors.h" #include "selectors.h"
#include "stackframe.h" #include "stackframe.h"
#include "process.h" #include "process.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(selector) DEFAULT_DEBUG_CHANNEL(selector)
@ -59,7 +59,7 @@ WORD WINAPI AllocSelector16( WORD sel )
count = sel ? ((GET_SEL_LIMIT(sel) >> 16) + 1) : 1; count = sel ? ((GET_SEL_LIMIT(sel) >> 16) + 1) : 1;
newsel = AllocSelectorArray16( count ); newsel = AllocSelectorArray16( count );
TRACE(selector, "(%04x): returning %04x\n", TRACE("(%04x): returning %04x\n",
sel, newsel ); sel, newsel );
if (!newsel) return 0; if (!newsel) return 0;
if (!sel) return newsel; /* nothing to copy */ if (!sel) return newsel; /* nothing to copy */
@ -166,7 +166,7 @@ void SELECTOR_FreeBlock( WORD sel, WORD count )
WORD i, nextsel; WORD i, nextsel;
ldt_entry entry; ldt_entry entry;
TRACE(selector, "(%04x,%d)\n", sel, count ); TRACE("(%04x,%d)\n", sel, count );
sel &= ~(__AHINCR - 1); /* clear bottom bits of selector */ sel &= ~(__AHINCR - 1); /* clear bottom bits of selector */
nextsel = sel + (count << __AHSHIFT); nextsel = sel + (count << __AHSHIFT);
@ -178,7 +178,7 @@ void SELECTOR_FreeBlock( WORD sel, WORD count )
GET_FS(fs); GET_FS(fs);
if ((fs >= sel) && (fs < nextsel)) if ((fs >= sel) && (fs < nextsel))
{ {
WARN(selector, "Freeing %%fs selector (%04x), not good.\n", fs ); WARN("Freeing %%fs selector (%04x), not good.\n", fs );
SET_FS( 0 ); SET_FS( 0 );
} }
GET_GS(gs); GET_GS(gs);
@ -262,7 +262,7 @@ WORD WINAPI AllocCStoDSAlias16( WORD sel )
ldt_entry entry; ldt_entry entry;
newsel = AllocSelectorArray16( 1 ); newsel = AllocSelectorArray16( 1 );
TRACE(selector, "(%04x): returning %04x\n", TRACE("(%04x): returning %04x\n",
sel, newsel ); sel, newsel );
if (!newsel) return 0; if (!newsel) return 0;
LDT_GetEntry( SELECTOR_TO_ENTRY(sel), &entry ); LDT_GetEntry( SELECTOR_TO_ENTRY(sel), &entry );
@ -281,7 +281,7 @@ WORD WINAPI AllocDStoCSAlias16( WORD sel )
ldt_entry entry; ldt_entry entry;
newsel = AllocSelectorArray16( 1 ); newsel = AllocSelectorArray16( 1 );
TRACE(selector, "(%04x): returning %04x\n", TRACE("(%04x): returning %04x\n",
sel, newsel ); sel, newsel );
if (!newsel) return 0; if (!newsel) return 0;
LDT_GetEntry( SELECTOR_TO_ENTRY(sel), &entry ); LDT_GetEntry( SELECTOR_TO_ENTRY(sel), &entry );

View File

@ -12,7 +12,7 @@
#include "wine/keyboard16.h" #include "wine/keyboard16.h"
#include "winerror.h" #include "winerror.h"
#include "ldt.h" #include "ldt.h"
#include "debug.h" #include "debugtools.h"
#include "winnls.h" #include "winnls.h"
DEFAULT_DEBUG_CHANNEL(string) DEFAULT_DEBUG_CHANNEL(string)
@ -87,7 +87,7 @@ SEGPTR WINAPI lstrcat16( SEGPTR dst, LPCSTR src )
*/ */
LPSTR WINAPI lstrcatA( LPSTR dst, LPCSTR src ) LPSTR WINAPI lstrcatA( LPSTR dst, LPCSTR src )
{ {
TRACE(string,"Append %s to %s\n", TRACE("Append %s to %s\n",
debugstr_a (src), debugstr_a (dst)); debugstr_a (src), debugstr_a (dst));
/* Windows does not check for NULL pointers here, so we don't either */ /* Windows does not check for NULL pointers here, so we don't either */
strcat( dst, src ); strcat( dst, src );
@ -101,7 +101,7 @@ LPSTR WINAPI lstrcatA( LPSTR dst, LPCSTR src )
LPWSTR WINAPI lstrcatW( LPWSTR dst, LPCWSTR src ) LPWSTR WINAPI lstrcatW( LPWSTR dst, LPCWSTR src )
{ {
register LPWSTR p = dst; register LPWSTR p = dst;
TRACE(string,"Append L%s to L%s\n", TRACE("Append L%s to L%s\n",
debugstr_w (src), debugstr_w (dst)); debugstr_w (src), debugstr_w (dst));
/* Windows does not check for NULL pointers here, so we don't either */ /* Windows does not check for NULL pointers here, so we don't either */
while (*p) p++; while (*p) p++;
@ -126,7 +126,7 @@ SEGPTR WINAPI lstrcatn16( SEGPTR dst, LPCSTR src, INT16 n )
LPSTR WINAPI lstrcatnA( LPSTR dst, LPCSTR src, INT n ) LPSTR WINAPI lstrcatnA( LPSTR dst, LPCSTR src, INT n )
{ {
register LPSTR p = dst; register LPSTR p = dst;
TRACE(string,"strcatn add %d chars from %s to %s\n", TRACE("strcatn add %d chars from %s to %s\n",
n, debugstr_an (src, n), debugstr_a (dst)); n, debugstr_an (src, n), debugstr_a (dst));
while (*p) p++; while (*p) p++;
if ((n -= (INT)(p - dst)) <= 0) return dst; if ((n -= (INT)(p - dst)) <= 0) return dst;
@ -141,7 +141,7 @@ LPSTR WINAPI lstrcatnA( LPSTR dst, LPCSTR src, INT n )
LPWSTR WINAPI lstrcatnW( LPWSTR dst, LPCWSTR src, INT n ) LPWSTR WINAPI lstrcatnW( LPWSTR dst, LPCWSTR src, INT n )
{ {
register LPWSTR p = dst; register LPWSTR p = dst;
TRACE(string,"strcatn add %d chars from L%s to L%s\n", TRACE("strcatn add %d chars from L%s to L%s\n",
n, debugstr_wn (src, n), debugstr_w (dst)); n, debugstr_wn (src, n), debugstr_w (dst));
while (*p) p++; while (*p) p++;
if ((n -= (INT)(p - dst)) <= 0) return dst; if ((n -= (INT)(p - dst)) <= 0) return dst;
@ -175,7 +175,7 @@ INT WINAPI lstrcmpA( LPCSTR str1, LPCSTR str2 )
*/ */
INT WINAPI lstrcmpW( LPCWSTR str1, LPCWSTR str2 ) INT WINAPI lstrcmpW( LPCWSTR str1, LPCWSTR str2 )
{ {
TRACE(string,"L%s and L%s\n", TRACE("L%s and L%s\n",
debugstr_w (str1), debugstr_w (str2)); debugstr_w (str1), debugstr_w (str2));
if (!str1 || !str2) { if (!str1 || !str2) {
SetLastError(ERROR_INVALID_PARAMETER); SetLastError(ERROR_INVALID_PARAMETER);
@ -199,7 +199,7 @@ INT16 WINAPI lstrcmpi16( LPCSTR str1, LPCSTR str2 )
* lstrcmpi32A (KERNEL32.605) * lstrcmpi32A (KERNEL32.605)
*/ */
INT WINAPI lstrcmpiA( LPCSTR str1, LPCSTR str2 ) INT WINAPI lstrcmpiA( LPCSTR str1, LPCSTR str2 )
{ TRACE(string,"strcmpi %s and %s\n", { TRACE("strcmpi %s and %s\n",
debugstr_a (str1), debugstr_a (str2)); debugstr_a (str1), debugstr_a (str2));
return CompareStringA(LOCALE_SYSTEM_DEFAULT,NORM_IGNORECASE,str1,-1,str2,-1)-2; return CompareStringA(LOCALE_SYSTEM_DEFAULT,NORM_IGNORECASE,str1,-1,str2,-1)-2;
} }
@ -214,7 +214,7 @@ INT WINAPI lstrcmpiW( LPCWSTR str1, LPCWSTR str2 )
#if 0 #if 0
/* Too much! (From registry loading.) */ /* Too much! (From registry loading.) */
TRACE(string,"strcmpi L%s and L%s\n", TRACE("strcmpi L%s and L%s\n",
debugstr_w (str1), debugstr_w (str2)); debugstr_w (str1), debugstr_w (str2));
#endif #endif
if (!str1 || !str2) { if (!str1 || !str2) {
@ -250,7 +250,7 @@ SEGPTR WINAPI lstrcpy16( SEGPTR dst, LPCSTR src )
*/ */
LPSTR WINAPI lstrcpyA( LPSTR dst, LPCSTR src ) LPSTR WINAPI lstrcpyA( LPSTR dst, LPCSTR src )
{ {
TRACE(string,"strcpy %s\n", debugstr_a (src)); TRACE("strcpy %s\n", debugstr_a (src));
/* In real windows the whole function is protected by an exception handler /* In real windows the whole function is protected by an exception handler
* that returns ERROR_INVALID_PARAMETER on faulty parameters * that returns ERROR_INVALID_PARAMETER on faulty parameters
* We currently just check for NULL. * We currently just check for NULL.
@ -271,7 +271,7 @@ LPSTR WINAPI lstrcpyA( LPSTR dst, LPCSTR src )
LPWSTR WINAPI lstrcpyW( LPWSTR dst, LPCWSTR src ) LPWSTR WINAPI lstrcpyW( LPWSTR dst, LPCWSTR src )
{ {
register LPWSTR p = dst; register LPWSTR p = dst;
TRACE(string,"strcpy L%s\n", debugstr_w (src)); TRACE("strcpy L%s\n", debugstr_w (src));
/* In real windows the whole function is protected by an exception handler /* In real windows the whole function is protected by an exception handler
* that returns ERROR_INVALID_PARAMETER on faulty parameters * that returns ERROR_INVALID_PARAMETER on faulty parameters
* We currently just check for NULL. * We currently just check for NULL.
@ -303,7 +303,7 @@ SEGPTR WINAPI lstrcpyn16( SEGPTR dst, LPCSTR src, INT16 n )
LPSTR WINAPI lstrcpynA( LPSTR dst, LPCSTR src, INT n ) LPSTR WINAPI lstrcpynA( LPSTR dst, LPCSTR src, INT n )
{ {
LPSTR p = dst; LPSTR p = dst;
TRACE(string,"strcpyn %s for %d chars\n", TRACE("strcpyn %s for %d chars\n",
debugstr_an (src,n), n); debugstr_an (src,n), n);
/* In real windows the whole function is protected by an exception handler /* In real windows the whole function is protected by an exception handler
* that returns ERROR_INVALID_PARAMETER on faulty parameters * that returns ERROR_INVALID_PARAMETER on faulty parameters
@ -327,7 +327,7 @@ LPSTR WINAPI lstrcpynA( LPSTR dst, LPCSTR src, INT n )
LPWSTR WINAPI lstrcpynW( LPWSTR dst, LPCWSTR src, INT n ) LPWSTR WINAPI lstrcpynW( LPWSTR dst, LPCWSTR src, INT n )
{ {
LPWSTR p = dst; LPWSTR p = dst;
TRACE(string,"strcpyn L%s for %d chars\n", TRACE("strcpyn L%s for %d chars\n",
debugstr_wn (src,n), n); debugstr_wn (src,n), n);
/* In real windows the whole function is protected by an exception handler /* In real windows the whole function is protected by an exception handler
* that returns ERROR_INVALID_PARAMETER on faulty parameters * that returns ERROR_INVALID_PARAMETER on faulty parameters
@ -361,7 +361,7 @@ INT WINAPI lstrlenA( LPCSTR str )
* in lstrlen() ... we check only for NULL pointer reference. * in lstrlen() ... we check only for NULL pointer reference.
* - Marcus Meissner * - Marcus Meissner
*/ */
TRACE(string,"strlen %s\n", debugstr_a (str)); TRACE("strlen %s\n", debugstr_a (str));
if (!str) return 0; if (!str) return 0;
return (INT)strlen(str); return (INT)strlen(str);
} }
@ -373,7 +373,7 @@ INT WINAPI lstrlenA( LPCSTR str )
INT WINAPI lstrlenW( LPCWSTR str ) INT WINAPI lstrlenW( LPCWSTR str )
{ {
INT len = 0; INT len = 0;
TRACE(string,"strlen L%s\n", debugstr_w (str)); TRACE("strlen L%s\n", debugstr_w (str));
if (!str) return 0; if (!str) return 0;
while (*str++) len++; while (*str++) len++;
return len; return len;
@ -385,7 +385,7 @@ INT WINAPI lstrlenW( LPCWSTR str )
*/ */
INT WINAPI lstrncmpA( LPCSTR str1, LPCSTR str2, INT n ) INT WINAPI lstrncmpA( LPCSTR str1, LPCSTR str2, INT n )
{ {
TRACE(string,"strncmp %s and %s for %d chars\n", TRACE("strncmp %s and %s for %d chars\n",
debugstr_an (str1, n), debugstr_an (str2, n), n); debugstr_an (str1, n), debugstr_an (str2, n), n);
return (INT)strncmp( str1, str2, n ); return (INT)strncmp( str1, str2, n );
} }
@ -396,7 +396,7 @@ INT WINAPI lstrncmpA( LPCSTR str1, LPCSTR str2, INT n )
*/ */
INT WINAPI lstrncmpW( LPCWSTR str1, LPCWSTR str2, INT n ) INT WINAPI lstrncmpW( LPCWSTR str1, LPCWSTR str2, INT n )
{ {
TRACE(string,"strncmp L%s and L%s for %d chars\n", TRACE("strncmp L%s and L%s for %d chars\n",
debugstr_wn (str1, n), debugstr_wn (str2, n), n); debugstr_wn (str1, n), debugstr_wn (str2, n), n);
if (!n) return 0; if (!n) return 0;
while ((--n > 0) && *str1 && (*str1 == *str2)) { str1++; str2++; } while ((--n > 0) && *str1 && (*str1 == *str2)) { str1++; str2++; }
@ -411,7 +411,7 @@ INT WINAPI lstrncmpiA( LPCSTR str1, LPCSTR str2, INT n )
{ {
INT res; INT res;
TRACE(string,"strncmpi %s and %s for %d chars\n", TRACE("strncmpi %s and %s for %d chars\n",
debugstr_an (str1, n), debugstr_an (str2, n), n); debugstr_an (str1, n), debugstr_an (str2, n), n);
if (!n) return 0; if (!n) return 0;
while ((--n > 0) && *str1) while ((--n > 0) && *str1)
@ -428,7 +428,7 @@ INT WINAPI lstrncmpiW( LPCWSTR str1, LPCWSTR str2, INT n )
{ {
INT res; INT res;
TRACE(string,"strncmpi L%s and L%s for %d chars\n", TRACE("strncmpi L%s and L%s for %d chars\n",
debugstr_wn (str1, n), debugstr_wn (str2, n), n); debugstr_wn (str1, n), debugstr_wn (str2, n), n);
if (!n) return 0; if (!n) return 0;
while ((--n > 0) && *str1) while ((--n > 0) && *str1)
@ -448,7 +448,7 @@ LPWSTR WINAPI lstrcpyAtoW( LPWSTR dst, LPCSTR src )
{ {
register LPWSTR p = dst; register LPWSTR p = dst;
TRACE(string,"%s\n",src); TRACE("%s\n",src);
while ((*p++ = (WCHAR)(unsigned char)*src++)); while ((*p++ = (WCHAR)(unsigned char)*src++));
return dst; return dst;
@ -462,7 +462,7 @@ LPSTR WINAPI lstrcpyWtoA( LPSTR dst, LPCWSTR src )
{ {
register LPSTR p = dst; register LPSTR p = dst;
TRACE(string,"L%s\n",debugstr_w(src)); TRACE("L%s\n",debugstr_w(src));
while ((*p++ = (CHAR)*src++)); while ((*p++ = (CHAR)*src++));
return dst; return dst;
@ -478,7 +478,7 @@ LPWSTR WINAPI lstrcpynAtoW( LPWSTR dst, LPCSTR src, INT n )
{ {
LPWSTR p = dst; LPWSTR p = dst;
TRACE(string,"%s %i\n",src, n); TRACE("%s %i\n",src, n);
while ((n-- > 1) && *src) *p++ = (WCHAR)(unsigned char)*src++; while ((n-- > 1) && *src) *p++ = (WCHAR)(unsigned char)*src++;
if (n >= 0) *p = 0; if (n >= 0) *p = 0;
@ -495,7 +495,7 @@ LPSTR WINAPI lstrcpynWtoA( LPSTR dst, LPCWSTR src, INT n )
{ {
LPSTR p = dst; LPSTR p = dst;
TRACE(string,"L%s %i\n",debugstr_w(src), n); TRACE("L%s %i\n",debugstr_w(src), n);
while ((n-- > 1) && *src) *p++ = (CHAR)*src++; while ((n-- > 1) && *src) *p++ = (CHAR)*src++;
if (n >= 0) *p = 0; if (n >= 0) *p = 0;
@ -508,7 +508,7 @@ LPSTR WINAPI lstrcpynWtoA( LPSTR dst, LPCWSTR src, INT n )
INT16 WINAPI UnicodeToAnsi16( LPCWSTR src, LPSTR dst, INT16 codepage ) INT16 WINAPI UnicodeToAnsi16( LPCWSTR src, LPSTR dst, INT16 codepage )
{ {
if ( codepage != -1 ) if ( codepage != -1 )
FIXME( string, "codepage %d not supported\n", codepage ); FIXME("codepage %d not supported\n", codepage );
lstrcpyWtoA( dst, src ); lstrcpyWtoA( dst, src );
@ -597,9 +597,9 @@ BOOL WINAPI CharToOemA( LPCSTR s, LPSTR d )
{ {
LPSTR oldd = d; LPSTR oldd = d;
if (!s || !d) return TRUE; if (!s || !d) return TRUE;
TRACE(string,"CharToOem %s\n", debugstr_a (s)); TRACE("CharToOem %s\n", debugstr_a (s));
while ((*d++ = ANSI_TO_OEM(*s++))); while ((*d++ = ANSI_TO_OEM(*s++)));
TRACE(string," to %s\n", debugstr_a (oldd)); TRACE(" to %s\n", debugstr_a (oldd));
return TRUE; return TRUE;
} }
@ -631,9 +631,9 @@ BOOL WINAPI CharToOemW( LPCWSTR s, LPSTR d )
{ {
LPSTR oldd = d; LPSTR oldd = d;
if (!s || !d) return TRUE; if (!s || !d) return TRUE;
TRACE(string,"CharToOem L%s\n", debugstr_w (s)); TRACE("CharToOem L%s\n", debugstr_w (s));
while ((*d++ = ANSI_TO_OEM(*s++))); while ((*d++ = ANSI_TO_OEM(*s++)));
TRACE(string," to %s\n", debugstr_a (oldd)); TRACE(" to %s\n", debugstr_a (oldd));
return TRUE; return TRUE;
} }
@ -644,9 +644,9 @@ BOOL WINAPI CharToOemW( LPCWSTR s, LPSTR d )
BOOL WINAPI OemToCharA( LPCSTR s, LPSTR d ) BOOL WINAPI OemToCharA( LPCSTR s, LPSTR d )
{ {
LPSTR oldd = d; LPSTR oldd = d;
TRACE(string,"OemToChar %s\n", debugstr_a (s)); TRACE("OemToChar %s\n", debugstr_a (s));
while ((*d++ = OEM_TO_ANSI(*s++))); while ((*d++ = OEM_TO_ANSI(*s++)));
TRACE(string," to %s\n", debugstr_a (oldd)); TRACE(" to %s\n", debugstr_a (oldd));
return TRUE; return TRUE;
} }
@ -656,7 +656,7 @@ BOOL WINAPI OemToCharA( LPCSTR s, LPSTR d )
*/ */
BOOL WINAPI OemToCharBuffA( LPCSTR s, LPSTR d, DWORD len ) BOOL WINAPI OemToCharBuffA( LPCSTR s, LPSTR d, DWORD len )
{ {
TRACE(string,"OemToCharBuff %s\n", debugstr_an (s, len)); TRACE("OemToCharBuff %s\n", debugstr_an (s, len));
while (len--) *d++ = OEM_TO_ANSI(*s++); while (len--) *d++ = OEM_TO_ANSI(*s++);
return TRUE; return TRUE;
} }
@ -667,7 +667,7 @@ BOOL WINAPI OemToCharBuffA( LPCSTR s, LPSTR d, DWORD len )
*/ */
BOOL WINAPI OemToCharBuffW( LPCSTR s, LPWSTR d, DWORD len ) BOOL WINAPI OemToCharBuffW( LPCSTR s, LPWSTR d, DWORD len )
{ {
TRACE(string,"OemToCharBuff %s\n", debugstr_an (s, len)); TRACE("OemToCharBuff %s\n", debugstr_an (s, len));
while (len--) *d++ = (WCHAR)OEM_TO_ANSI(*s++); while (len--) *d++ = (WCHAR)OEM_TO_ANSI(*s++);
return TRUE; return TRUE;
} }
@ -695,7 +695,7 @@ INT WINAPI WideCharToLocal(
LPWSTR pWide, LPWSTR pWide,
INT dwChars) INT dwChars)
{ *pLocal = 0; { *pLocal = 0;
TRACE(string,"(%p, %s, %i)\n", pLocal, debugstr_w(pWide),dwChars); TRACE("(%p, %s, %i)\n", pLocal, debugstr_w(pWide),dwChars);
WideCharToMultiByte(CP_ACP,0,pWide,-1,pLocal,dwChars,NULL,NULL); WideCharToMultiByte(CP_ACP,0,pWide,-1,pLocal,dwChars,NULL,NULL);
return strlen(pLocal); return strlen(pLocal);
} }
@ -711,7 +711,7 @@ INT WINAPI LocalToWideChar(
LPSTR pLocal, LPSTR pLocal,
INT dwChars) INT dwChars)
{ *pWide = 0; { *pWide = 0;
TRACE(string,"(%p, %s, %i)\n",pWide, pLocal, dwChars); TRACE("(%p, %s, %i)\n",pWide, pLocal, dwChars);
MultiByteToWideChar(CP_ACP,0,pLocal,-1,pWide,dwChars); MultiByteToWideChar(CP_ACP,0,pLocal,-1,pWide,dwChars);
return lstrlenW(pWide); return lstrlenW(pWide);
} }
@ -730,7 +730,7 @@ LPSTR WINAPI lstrrchr( LPCSTR lpStart, LPCSTR lpEnd, WORD wMatch )
{ {
LPCSTR lpGotIt = NULL; LPCSTR lpGotIt = NULL;
TRACE(string,"(%s, %s)\n", lpStart, lpEnd); TRACE("(%s, %s)\n", lpStart, lpEnd);
if (!lpEnd) lpEnd = lpStart + strlen(lpStart); if (!lpEnd) lpEnd = lpStart + strlen(lpStart);
@ -754,7 +754,7 @@ LPWSTR WINAPI lstrrchrw( LPCWSTR lpStart, LPCWSTR lpEnd, WORD wMatch )
{ {
LPCWSTR lpGotIt = NULL; LPCWSTR lpGotIt = NULL;
TRACE(string,"(%p, %p, %c)\n", lpStart, lpEnd, wMatch); TRACE("(%p, %p, %c)\n", lpStart, lpEnd, wMatch);
if (!lpEnd) lpEnd = lpStart + lstrlenW(lpStart); if (!lpEnd) lpEnd = lpStart + lstrlenW(lpStart);
for(; lpStart < lpEnd; lpStart = CharNextW(lpStart)) for(; lpStart < lpEnd; lpStart = CharNextW(lpStart))
@ -775,7 +775,7 @@ LPWSTR WINAPI strstrw( LPCWSTR lpFirst, LPCWSTR lpSrch) {
UINT uSrchLen = (UINT)lstrlenW(lpSrch); UINT uSrchLen = (UINT)lstrlenW(lpSrch);
WORD wMatchBeg = *(WORD*)lpSrch; WORD wMatchBeg = *(WORD*)lpSrch;
TRACE(string,"(%p, %p)\n", lpFirst, lpSrch); TRACE("(%p, %p)\n", lpFirst, lpSrch);
for(; for(;
((lpFirst=CRTDLL_wcschr(lpFirst, wMatchBeg))!=0) && ((lpFirst=CRTDLL_wcschr(lpFirst, wMatchBeg))!=0) &&

View File

@ -21,7 +21,7 @@
#include "xmalloc.h" #include "xmalloc.h"
#include "global.h" #include "global.h"
#include "server.h" #include "server.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(virtual) DEFAULT_DEBUG_CHANNEL(virtual)
@ -118,18 +118,18 @@ static void VIRTUAL_DumpView( FILE_VIEW *view )
UINT addr = view->base; UINT addr = view->base;
BYTE prot = view->prot[0]; BYTE prot = view->prot[0];
DUMP( "View: %08x - %08x%s", DPRINTF( "View: %08x - %08x%s",
view->base, view->base + view->size - 1, view->base, view->base + view->size - 1,
(view->flags & VFLAG_SYSTEM) ? " (system)" : "" ); (view->flags & VFLAG_SYSTEM) ? " (system)" : "" );
if (view->mapping) if (view->mapping)
DUMP( " %d @ %08x\n", view->mapping, view->offset ); DPRINTF( " %d @ %08x\n", view->mapping, view->offset );
else else
DUMP( " (anonymous)\n"); DPRINTF( " (anonymous)\n");
for (count = i = 1; i < view->size >> page_shift; i++, count++) for (count = i = 1; i < view->size >> page_shift; i++, count++)
{ {
if (view->prot[i] == prot) continue; if (view->prot[i] == prot) continue;
DUMP( " %08x - %08x %s\n", DPRINTF( " %08x - %08x %s\n",
addr, addr + (count << page_shift) - 1, addr, addr + (count << page_shift) - 1,
VIRTUAL_GetProtStr(prot) ); VIRTUAL_GetProtStr(prot) );
addr += (count << page_shift); addr += (count << page_shift);
@ -137,7 +137,7 @@ static void VIRTUAL_DumpView( FILE_VIEW *view )
count = 0; count = 0;
} }
if (count) if (count)
DUMP( " %08x - %08x %s\n", DPRINTF( " %08x - %08x %s\n",
addr, addr + (count << page_shift) - 1, addr, addr + (count << page_shift) - 1,
VIRTUAL_GetProtStr(prot) ); VIRTUAL_GetProtStr(prot) );
} }
@ -149,7 +149,7 @@ static void VIRTUAL_DumpView( FILE_VIEW *view )
void VIRTUAL_Dump(void) void VIRTUAL_Dump(void)
{ {
FILE_VIEW *view = VIRTUAL_FirstView; FILE_VIEW *view = VIRTUAL_FirstView;
DUMP( "\nDump of all virtual memory views:\n\n" ); DPRINTF( "\nDump of all virtual memory views:\n\n" );
while (view) while (view)
{ {
VIRTUAL_DumpView( view ); VIRTUAL_DumpView( view );
@ -365,7 +365,7 @@ static BOOL VIRTUAL_SetProt(
UINT size, /* [in] Size in bytes */ UINT size, /* [in] Size in bytes */
BYTE vprot /* [in] Protections to use */ BYTE vprot /* [in] Protections to use */
) { ) {
TRACE(virtual, "%08x-%08x %s\n", TRACE("%08x-%08x %s\n",
base, base + size - 1, VIRTUAL_GetProtStr( vprot ) ); base, base + size - 1, VIRTUAL_GetProtStr( vprot ) );
if (mprotect( (void *)base, size, VIRTUAL_GetUnixProt(vprot) )) if (mprotect( (void *)base, size, VIRTUAL_GetUnixProt(vprot) ))
@ -533,7 +533,7 @@ LPVOID WINAPI VirtualAlloc(
UINT base, ptr, view_size; UINT base, ptr, view_size;
BYTE vprot; BYTE vprot;
TRACE(virtual, "%08x %08lx %lx %08lx\n", TRACE("%08x %08lx %lx %08lx\n",
(UINT)addr, size, type, protect ); (UINT)addr, size, type, protect );
/* Round parameters to a page boundary */ /* Round parameters to a page boundary */
@ -566,7 +566,7 @@ LPVOID WINAPI VirtualAlloc(
/* FIXME: MEM_TOP_DOWN allocates the largest possible address. /* FIXME: MEM_TOP_DOWN allocates the largest possible address.
* Is there _ANY_ way to do it with UNIX mmap()? * Is there _ANY_ way to do it with UNIX mmap()?
*/ */
WARN(virtual,"MEM_TOP_DOWN ignored\n"); WARN("MEM_TOP_DOWN ignored\n");
type &= ~MEM_TOP_DOWN; type &= ~MEM_TOP_DOWN;
} }
/* Compute the protection flags */ /* Compute the protection flags */
@ -655,7 +655,7 @@ BOOL WINAPI VirtualFree(
FILE_VIEW *view; FILE_VIEW *view;
UINT base; UINT base;
TRACE(virtual, "%08x %08lx %lx\n", TRACE("%08x %08lx %lx\n",
(UINT)addr, size, type ); (UINT)addr, size, type );
/* Fix the parameters */ /* Fix the parameters */
@ -752,7 +752,7 @@ BOOL WINAPI VirtualProtect(
UINT base, i; UINT base, i;
BYTE vprot, *p; BYTE vprot, *p;
TRACE(virtual, "%08x %08lx %08lx\n", TRACE("%08x %08lx %08lx\n",
(UINT)addr, size, new_prot ); (UINT)addr, size, new_prot );
/* Fix the parameters */ /* Fix the parameters */
@ -803,7 +803,7 @@ BOOL WINAPI VirtualProtectEx(
{ {
if (PROCESS_IsCurrent( handle )) if (PROCESS_IsCurrent( handle ))
return VirtualProtect( addr, size, new_prot, old_prot ); return VirtualProtect( addr, size, new_prot, old_prot );
ERR(virtual,"Unsupported on other process\n"); ERR("Unsupported on other process\n");
return FALSE; return FALSE;
} }
@ -892,7 +892,7 @@ DWORD WINAPI VirtualQueryEx(
{ {
if (PROCESS_IsCurrent( handle )) if (PROCESS_IsCurrent( handle ))
return VirtualQuery( addr, info, len ); return VirtualQuery( addr, info, len );
ERR(virtual,"Unsupported on other process\n"); ERR("Unsupported on other process\n");
return 0; return 0;
} }
@ -1057,7 +1057,7 @@ HANDLE WINAPI CreateFileMappingA(
/* Check parameters */ /* Check parameters */
TRACE(virtual,"(%x,%p,%08lx,%08lx%08lx,%s)\n", TRACE("(%x,%p,%08lx,%08lx%08lx,%s)\n",
hFile, sa, protect, size_high, size_low, debugstr_a(name) ); hFile, sa, protect, size_high, size_low, debugstr_a(name) );
vprot = VIRTUAL_GetProt( protect ); vprot = VIRTUAL_GetProt( protect );
@ -1202,7 +1202,7 @@ LPVOID WINAPI MapViewOfFileEx(
goto error; goto error;
if (info.size_high || offset_high) if (info.size_high || offset_high)
ERR(virtual, "Offsets larger than 4Gb not supported\n"); ERR("Offsets larger than 4Gb not supported\n");
if ((offset_low >= info.size_low) || if ((offset_low >= info.size_low) ||
(count > info.size_low - offset_low)) (count > info.size_low - offset_low))
@ -1237,7 +1237,7 @@ LPVOID WINAPI MapViewOfFileEx(
/* Map the file */ /* Map the file */
TRACE(virtual, "handle=%x size=%x offset=%lx\n", TRACE("handle=%x size=%x offset=%lx\n",
handle, size, offset_low ); handle, size, offset_low );
ptr = (UINT)FILE_dommap( unix_handle, ptr = (UINT)FILE_dommap( unix_handle,
@ -1289,7 +1289,7 @@ BOOL WINAPI FlushViewOfFile(
FILE_VIEW *view; FILE_VIEW *view;
UINT addr = ROUND_ADDR( base ); UINT addr = ROUND_ADDR( base );
TRACE(virtual, "FlushViewOfFile at %p for %ld bytes\n", TRACE("FlushViewOfFile at %p for %ld bytes\n",
base, cbFlush ); base, cbFlush );
if (!(view = VIRTUAL_FindView( addr ))) if (!(view = VIRTUAL_FindView( addr )))

View File

@ -8,7 +8,7 @@
#include "winbase.h" #include "winbase.h"
#include "brush.h" #include "brush.h"
#include "bitmap.h" #include "bitmap.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(gdi) DEFAULT_DEBUG_CHANNEL(gdi)
@ -26,7 +26,7 @@ HBRUSH16 WINAPI CreateBrushIndirect16( const LOGBRUSH16 * brush )
brushPtr->logbrush.lbColor = brush->lbColor; brushPtr->logbrush.lbColor = brush->lbColor;
brushPtr->logbrush.lbHatch = brush->lbHatch; brushPtr->logbrush.lbHatch = brush->lbHatch;
GDI_HEAP_UNLOCK( hbrush ); GDI_HEAP_UNLOCK( hbrush );
TRACE(gdi, "%04x\n", hbrush); TRACE("%04x\n", hbrush);
return hbrush; return hbrush;
} }
@ -44,7 +44,7 @@ HBRUSH WINAPI CreateBrushIndirect( const LOGBRUSH * brush )
brushPtr->logbrush.lbColor = brush->lbColor; brushPtr->logbrush.lbColor = brush->lbColor;
brushPtr->logbrush.lbHatch = brush->lbHatch; brushPtr->logbrush.lbHatch = brush->lbHatch;
GDI_HEAP_UNLOCK( hbrush ); GDI_HEAP_UNLOCK( hbrush );
TRACE(gdi, "%08x\n", hbrush); TRACE("%08x\n", hbrush);
return hbrush; return hbrush;
} }
@ -56,7 +56,7 @@ HBRUSH16 WINAPI CreateHatchBrush16( INT16 style, COLORREF color )
{ {
LOGBRUSH logbrush; LOGBRUSH logbrush;
TRACE(gdi, "%d %06lx\n", style, color ); TRACE("%d %06lx\n", style, color );
logbrush.lbStyle = BS_HATCHED; logbrush.lbStyle = BS_HATCHED;
logbrush.lbColor = color; logbrush.lbColor = color;
@ -74,7 +74,7 @@ HBRUSH WINAPI CreateHatchBrush( INT style, COLORREF color )
{ {
LOGBRUSH logbrush; LOGBRUSH logbrush;
TRACE(gdi, "%d %06lx\n", style, color ); TRACE("%d %06lx\n", style, color );
logbrush.lbStyle = BS_HATCHED; logbrush.lbStyle = BS_HATCHED;
logbrush.lbColor = color; logbrush.lbColor = color;
@ -100,7 +100,7 @@ HBRUSH16 WINAPI CreatePatternBrush16( HBITMAP16 hbitmap )
HBRUSH WINAPI CreatePatternBrush( HBITMAP hbitmap ) HBRUSH WINAPI CreatePatternBrush( HBITMAP hbitmap )
{ {
LOGBRUSH logbrush = { BS_PATTERN, 0, 0 }; LOGBRUSH logbrush = { BS_PATTERN, 0, 0 };
TRACE(gdi, "%04x\n", hbitmap ); TRACE("%04x\n", hbitmap );
logbrush.lbHatch = (INT)BITMAP_CopyBitmap( hbitmap ); logbrush.lbHatch = (INT)BITMAP_CopyBitmap( hbitmap );
if(!logbrush.lbHatch) if(!logbrush.lbHatch)
@ -119,7 +119,7 @@ HBRUSH16 WINAPI CreateDIBPatternBrush16( HGLOBAL16 hbitmap, UINT16 coloruse )
BITMAPINFO *info, *newInfo; BITMAPINFO *info, *newInfo;
INT size; INT size;
TRACE(gdi, "%04x\n", hbitmap ); TRACE("%04x\n", hbitmap );
logbrush.lbStyle = BS_DIBPATTERN; logbrush.lbStyle = BS_DIBPATTERN;
logbrush.lbColor = coloruse; logbrush.lbColor = coloruse;
@ -173,7 +173,7 @@ HBRUSH WINAPI CreateDIBPatternBrush(
BITMAPINFO *info, *newInfo; BITMAPINFO *info, *newInfo;
INT size; INT size;
TRACE(gdi, "%04x\n", hbitmap ); TRACE("%04x\n", hbitmap );
logbrush.lbStyle = BS_DIBPATTERN; logbrush.lbStyle = BS_DIBPATTERN;
logbrush.lbColor = coloruse; logbrush.lbColor = coloruse;
@ -226,7 +226,7 @@ HBRUSH WINAPI CreateDIBPatternBrushPt(
BITMAPINFO *newInfo; BITMAPINFO *newInfo;
INT size; INT size;
TRACE(gdi, "%p %ldx%ld %dbpp\n", info, info->bmiHeader.biWidth, TRACE("%p %ldx%ld %dbpp\n", info, info->bmiHeader.biWidth,
info->bmiHeader.biHeight, info->bmiHeader.biBitCount); info->bmiHeader.biHeight, info->bmiHeader.biBitCount);
logbrush.lbStyle = BS_DIBPATTERN; logbrush.lbStyle = BS_DIBPATTERN;
@ -262,7 +262,7 @@ HBRUSH16 WINAPI CreateSolidBrush16( COLORREF color )
{ {
LOGBRUSH logbrush; LOGBRUSH logbrush;
TRACE(gdi, "%06lx\n", color ); TRACE("%06lx\n", color );
logbrush.lbStyle = BS_SOLID; logbrush.lbStyle = BS_SOLID;
logbrush.lbColor = color; logbrush.lbColor = color;
@ -279,7 +279,7 @@ HBRUSH WINAPI CreateSolidBrush( COLORREF color )
{ {
LOGBRUSH logbrush; LOGBRUSH logbrush;
TRACE(gdi, "%06lx\n", color ); TRACE("%06lx\n", color );
logbrush.lbStyle = BS_SOLID; logbrush.lbStyle = BS_SOLID;
logbrush.lbColor = color; logbrush.lbColor = color;
@ -388,7 +388,7 @@ INT BRUSH_GetObject( BRUSHOBJ * brush, INT count, LPSTR buffer )
*/ */
BOOL16 WINAPI SetSolidBrush16(HBRUSH16 hBrush, COLORREF newColor ) BOOL16 WINAPI SetSolidBrush16(HBRUSH16 hBrush, COLORREF newColor )
{ {
FIXME(gdi, "(hBrush %04x, newColor %04x): stub!\n", hBrush, (int)newColor); FIXME("(hBrush %04x, newColor %04x): stub!\n", hBrush, (int)newColor);
return(FALSE); return(FALSE);
} }

View File

@ -6,7 +6,7 @@
*/ */
#include "color.h" #include "color.h"
#include "debug.h" #include "debugtools.h"
#include "palette.h" #include "palette.h"
#include "windef.h" #include "windef.h"
@ -165,7 +165,7 @@ COLORREF COLOR_LookupNearestColor( PALETTEENTRY* palPalEntry, int size, COLORREF
{ {
if( (i = color & 0x0000ffff) >= size ) if( (i = color & 0x0000ffff) >= size )
{ {
WARN(palette, "RGB(%lx) : idx %d is out of bounds, assuming NULL\n", color, i); WARN("RGB(%lx) : idx %d is out of bounds, assuming NULL\n", color, i);
color = *(COLORREF*)palPalEntry; color = *(COLORREF*)palPalEntry;
} }
else color = *(COLORREF*)(palPalEntry + i); else color = *(COLORREF*)(palPalEntry + i);

View File

@ -15,7 +15,7 @@
#include "dc.h" #include "dc.h"
#include "gdi.h" #include "gdi.h"
#include "heap.h" #include "heap.h"
#include "debug.h" #include "debugtools.h"
#include "font.h" #include "font.h"
#include "winerror.h" #include "winerror.h"
#include "wine/winuser16.h" #include "wine/winuser16.h"
@ -226,7 +226,7 @@ HDC16 WINAPI GetDCState16( HDC16 hdc )
} }
newdc = (DC *) GDI_HEAP_LOCK( handle ); newdc = (DC *) GDI_HEAP_LOCK( handle );
TRACE(dc, "(%04x): returning %04x\n", hdc, handle ); TRACE("(%04x): returning %04x\n", hdc, handle );
newdc->w.flags = dc->w.flags | DC_SAVED; newdc->w.flags = dc->w.flags | DC_SAVED;
newdc->w.devCaps = dc->w.devCaps; newdc->w.devCaps = dc->w.devCaps;
@ -317,7 +317,7 @@ void WINAPI SetDCState16( HDC16 hdc, HDC16 hdcs )
GDI_HEAP_UNLOCK( hdcs ); GDI_HEAP_UNLOCK( hdcs );
return; return;
} }
TRACE(dc, "%04x %04x\n", hdc, hdcs ); TRACE("%04x %04x\n", hdc, hdcs );
dc->w.flags = dcs->w.flags & ~DC_SAVED; dc->w.flags = dcs->w.flags & ~DC_SAVED;
dc->w.devCaps = dcs->w.devCaps; dc->w.devCaps = dcs->w.devCaps;
@ -436,7 +436,7 @@ INT WINAPI SaveDC( HDC hdc )
dcs->header.hNext = dc->header.hNext; dcs->header.hNext = dc->header.hNext;
dc->header.hNext = hdcs; dc->header.hNext = hdcs;
TRACE(dc, "(%04x): returning %d\n", hdc, dc->saveLevel+1 ); TRACE("(%04x): returning %d\n", hdc, dc->saveLevel+1 );
ret = ++dc->saveLevel; ret = ++dc->saveLevel;
GDI_HEAP_UNLOCK( hdcs ); GDI_HEAP_UNLOCK( hdcs );
GDI_HEAP_UNLOCK( hdc ); GDI_HEAP_UNLOCK( hdc );
@ -461,7 +461,7 @@ BOOL WINAPI RestoreDC( HDC hdc, INT level )
DC * dc, * dcs; DC * dc, * dcs;
BOOL success; BOOL success;
TRACE(dc, "%04x %d\n", hdc, level ); TRACE("%04x %d\n", hdc, level );
dc = DC_GetDCPtr( hdc ); dc = DC_GetDCPtr( hdc );
if(!dc) return FALSE; if(!dc) return FALSE;
if(dc->funcs->pRestoreDC) if(dc->funcs->pRestoreDC)
@ -518,13 +518,13 @@ HDC16 WINAPI CreateDC16( LPCSTR driver, LPCSTR device, LPCSTR output,
if (!(dc = DC_AllocDC( funcs ))) return 0; if (!(dc = DC_AllocDC( funcs ))) return 0;
dc->w.flags = 0; dc->w.flags = 0;
TRACE(dc, "(driver=%s, device=%s, output=%s): returning %04x\n", TRACE("(driver=%s, device=%s, output=%s): returning %04x\n",
debugstr_a(driver), debugstr_a(device), debugstr_a(output), dc->hSelf ); debugstr_a(driver), debugstr_a(device), debugstr_a(output), dc->hSelf );
if (dc->funcs->pCreateDC && if (dc->funcs->pCreateDC &&
!dc->funcs->pCreateDC( dc, driver, device, output, initData )) !dc->funcs->pCreateDC( dc, driver, device, output, initData ))
{ {
WARN(dc, "creation aborted by device\n" ); WARN("creation aborted by device\n" );
GDI_HEAP_FREE( dc->hSelf ); GDI_HEAP_FREE( dc->hSelf );
return 0; return 0;
} }
@ -620,7 +620,7 @@ HDC WINAPI CreateCompatibleDC( HDC hdc )
if (!(dc = DC_AllocDC( funcs ))) return 0; if (!(dc = DC_AllocDC( funcs ))) return 0;
TRACE(dc, "(%04x): returning %04x\n", TRACE("(%04x): returning %04x\n",
hdc, dc->hSelf ); hdc, dc->hSelf );
/* Create default bitmap */ /* Create default bitmap */
@ -637,7 +637,7 @@ HDC WINAPI CreateCompatibleDC( HDC hdc )
if (dc->funcs->pCreateDC && if (dc->funcs->pCreateDC &&
!dc->funcs->pCreateDC( dc, NULL, NULL, NULL, NULL )) !dc->funcs->pCreateDC( dc, NULL, NULL, NULL, NULL ))
{ {
WARN(dc, "creation aborted by device\n"); WARN("creation aborted by device\n");
DeleteObject( hbitmap ); DeleteObject( hbitmap );
GDI_HEAP_FREE( dc->hSelf ); GDI_HEAP_FREE( dc->hSelf );
return 0; return 0;
@ -666,7 +666,7 @@ BOOL WINAPI DeleteDC( HDC hdc )
DC * dc = (DC *) GDI_GetObjPtr( hdc, DC_MAGIC ); DC * dc = (DC *) GDI_GetObjPtr( hdc, DC_MAGIC );
if (!dc) return FALSE; if (!dc) return FALSE;
TRACE(dc, "%04x\n", hdc ); TRACE("%04x\n", hdc );
/* Call hook procedure to check whether is it OK to delete this DC */ /* Call hook procedure to check whether is it OK to delete this DC */
if ( dc->hookProc && !(dc->w.flags & (DC_SAVED | DC_MEMORY)) if ( dc->hookProc && !(dc->w.flags & (DC_SAVED | DC_MEMORY))
@ -710,7 +710,7 @@ BOOL WINAPI DeleteDC( HDC hdc )
*/ */
HDC16 WINAPI ResetDC16( HDC16 hdc, const DEVMODEA *devmode ) HDC16 WINAPI ResetDC16( HDC16 hdc, const DEVMODEA *devmode )
{ {
FIXME(dc, "stub\n" ); FIXME("stub\n" );
return hdc; return hdc;
} }
@ -720,7 +720,7 @@ HDC16 WINAPI ResetDC16( HDC16 hdc, const DEVMODEA *devmode )
*/ */
HDC WINAPI ResetDCA( HDC hdc, const DEVMODEA *devmode ) HDC WINAPI ResetDCA( HDC hdc, const DEVMODEA *devmode )
{ {
FIXME(dc, "stub\n" ); FIXME("stub\n" );
return hdc; return hdc;
} }
@ -730,7 +730,7 @@ HDC WINAPI ResetDCA( HDC hdc, const DEVMODEA *devmode )
*/ */
HDC WINAPI ResetDCW( HDC hdc, const DEVMODEW *devmode ) HDC WINAPI ResetDCW( HDC hdc, const DEVMODEW *devmode )
{ {
FIXME(dc, "stub\n" ); FIXME("stub\n" );
return hdc; return hdc;
} }
@ -784,7 +784,7 @@ INT WINAPI GetDeviceCaps( HDC hdc, INT cap )
return 0; return 0;
} }
TRACE(dc, "(%04x,%d): returning %d\n", TRACE("(%04x,%d): returning %d\n",
hdc, cap, *(WORD *)(((char *)dc->w.devCaps) + cap) ); hdc, cap, *(WORD *)(((char *)dc->w.devCaps) + cap) );
ret = *(WORD *)(((char *)dc->w.devCaps) + cap); ret = *(WORD *)(((char *)dc->w.devCaps) + cap);
GDI_HEAP_UNLOCK( hdc ); GDI_HEAP_UNLOCK( hdc );
@ -1194,7 +1194,7 @@ BOOL16 WINAPI SetDCHook( HDC16 hdc, FARPROC16 hookProc, DWORD dwHookData )
{ {
DC *dc = (DC *)GDI_GetObjPtr( hdc, DC_MAGIC ); DC *dc = (DC *)GDI_GetObjPtr( hdc, DC_MAGIC );
TRACE(dc, "hookProc %08x, default is %08x\n", TRACE("hookProc %08x, default is %08x\n",
(UINT)hookProc, (UINT)DCHook16 ); (UINT)hookProc, (UINT)DCHook16 );
if (!dc) return FALSE; if (!dc) return FALSE;
@ -1232,7 +1232,7 @@ WORD WINAPI SetHookFlags16(HDC16 hDC, WORD flags)
/* "Undocumented Windows" info is slightly confusing. /* "Undocumented Windows" info is slightly confusing.
*/ */
TRACE(dc,"hDC %04x, flags %04x\n",hDC,flags); TRACE("hDC %04x, flags %04x\n",hDC,flags);
if( flags & DCHF_INVALIDATEVISRGN ) if( flags & DCHF_INVALIDATEVISRGN )
dc->w.flags |= DC_DIRTY; dc->w.flags |= DC_DIRTY;
@ -1279,7 +1279,7 @@ UINT16 WINAPI GetBoundsRect16(HDC16 hdc, LPRECT16 rect, UINT16 flags)
*/ */
UINT WINAPI GetBoundsRect(HDC hdc, LPRECT rect, UINT flags) UINT WINAPI GetBoundsRect(HDC hdc, LPRECT rect, UINT flags)
{ {
FIXME(dc, "(): stub\n"); FIXME("(): stub\n");
return DCB_RESET; /* bounding rectangle always empty */ return DCB_RESET; /* bounding rectangle always empty */
} }
@ -1289,7 +1289,7 @@ UINT WINAPI GetBoundsRect(HDC hdc, LPRECT rect, UINT flags)
UINT16 WINAPI SetBoundsRect16(HDC16 hdc, const RECT16* rect, UINT16 flags) UINT16 WINAPI SetBoundsRect16(HDC16 hdc, const RECT16* rect, UINT16 flags)
{ {
if ( (flags & DCB_ACCUMULATE) || (flags & DCB_ENABLE) ) if ( (flags & DCB_ACCUMULATE) || (flags & DCB_ENABLE) )
FIXME( dc, "(%04x, %p, %04x): stub\n", hdc, rect, flags ); FIXME("(%04x, %p, %04x): stub\n", hdc, rect, flags );
return DCB_RESET | DCB_DISABLE; /* bounding rectangle always empty and disabled*/ return DCB_RESET | DCB_DISABLE; /* bounding rectangle always empty and disabled*/
} }
@ -1299,7 +1299,7 @@ UINT16 WINAPI SetBoundsRect16(HDC16 hdc, const RECT16* rect, UINT16 flags)
*/ */
UINT WINAPI SetBoundsRect(HDC hdc, const RECT* rect, UINT flags) UINT WINAPI SetBoundsRect(HDC hdc, const RECT* rect, UINT flags)
{ {
FIXME(dc, "(): stub\n"); FIXME("(): stub\n");
return DCB_DISABLE; /* bounding rectangle always empty */ return DCB_DISABLE; /* bounding rectangle always empty */
} }
@ -1312,7 +1312,7 @@ UINT WINAPI SetBoundsRect(HDC hdc, const RECT* rect, UINT flags)
*/ */
void WINAPI Death16(HDC16 hDC) void WINAPI Death16(HDC16 hDC)
{ {
MSG("Death(%04x) called. Application enters text mode...\n", hDC); MESSAGE("Death(%04x) called. Application enters text mode...\n", hDC);
} }
/*********************************************************************** /***********************************************************************
@ -1323,5 +1323,5 @@ void WINAPI Death16(HDC16 hDC)
void WINAPI Resurrection16(HDC16 hDC, void WINAPI Resurrection16(HDC16 hDC,
WORD w1, WORD w2, WORD w3, WORD w4, WORD w5, WORD w6) WORD w1, WORD w2, WORD w3, WORD w4, WORD w5, WORD w6)
{ {
MSG("Resurrection(%04x, %04x, %04x, %04x, %04x, %04x, %04x) called. Application left text mode.\n", hDC, w1, w2, w3, w4, w5, w6); MESSAGE("Resurrection(%04x, %04x, %04x, %04x, %04x, %04x, %04x) called. Application left text mode.\n", hDC, w1, w2, w3, w4, w5, w6);
} }

View File

@ -9,7 +9,7 @@
#include "bitmap.h" #include "bitmap.h"
#include "callback.h" #include "callback.h"
#include "dc.h" #include "dc.h"
#include "debug.h" #include "debugtools.h"
#include "monitor.h" #include "monitor.h"
#include "palette.h" #include "palette.h"
@ -35,7 +35,7 @@ int DIB_GetDIBWidthBytes( int width, int depth )
case 24: words = (width * 3 + 3)/4; break; case 24: words = (width * 3 + 3)/4; break;
default: default:
WARN(bitmap, "(%d): Unsupported depth\n", depth ); WARN("(%d): Unsupported depth\n", depth );
/* fall through */ /* fall through */
case 32: case 32:
words = width; words = width;
@ -107,7 +107,7 @@ int DIB_GetBitmapInfo( const BITMAPINFOHEADER *header, DWORD *width,
*compr = 0; *compr = 0;
return 0; return 0;
} }
WARN(bitmap, "(%ld): wrong size for header\n", header->biSize ); WARN("(%ld): wrong size for header\n", header->biSize );
return -1; return -1;
} }
@ -253,7 +253,7 @@ INT WINAPI SetDIBitsToDevice(HDC hdc, INT xDest, INT yDest, DWORD cx,
ySrc, startscan, lines, bits, ySrc, startscan, lines, bits,
info, coloruse ); info, coloruse );
else { else {
FIXME(bitmap, "unimplemented on hdc %08x\n", hdc); FIXME("unimplemented on hdc %08x\n", hdc);
ret = 0; ret = 0;
} }
@ -565,7 +565,7 @@ INT WINAPI GetDIBits(
} }
} }
TRACE(bitmap, "biSizeImage = %ld, biWidth = %ld, biHeight = %ld\n", TRACE("biSizeImage = %ld, biWidth = %ld, biHeight = %ld\n",
info->bmiHeader.biSizeImage, info->bmiHeader.biWidth, info->bmiHeader.biSizeImage, info->bmiHeader.biWidth,
info->bmiHeader.biHeight); info->bmiHeader.biHeight);
@ -640,7 +640,7 @@ HBITMAP WINAPI CreateDIBitmap( HDC hdc, const BITMAPINFOHEADER *header,
} }
else else
{ {
WARN(bitmap, "(%ld): wrong size for data\n", WARN("(%ld): wrong size for data\n",
data->bmiHeader.biSize ); data->bmiHeader.biSize );
return 0; return 0;
} }
@ -736,7 +736,7 @@ void DIB_FixColorsToLoadflags(BITMAPINFO * bmi, UINT loadflags, BYTE pix)
if (bmi->bmiHeader.biSize == sizeof(BITMAPINFOHEADER)) incr = 4; if (bmi->bmiHeader.biSize == sizeof(BITMAPINFOHEADER)) incr = 4;
else if (bmi->bmiHeader.biSize == sizeof(BITMAPCOREHEADER)) incr = 3; else if (bmi->bmiHeader.biSize == sizeof(BITMAPCOREHEADER)) incr = 3;
else { else {
WARN(bitmap, "Wrong bitmap header size!\n"); WARN("Wrong bitmap header size!\n");
return; return;
} }
colors = bmi->bmiHeader.biClrUsed; colors = bmi->bmiHeader.biClrUsed;
@ -752,11 +752,11 @@ void DIB_FixColorsToLoadflags(BITMAPINFO * bmi, UINT loadflags, BYTE pix)
case 4: pix = pix >> 4; break; case 4: pix = pix >> 4; break;
case 8: break; case 8: break;
default: default:
WARN(bitmap, "(%d): Unsupported depth\n", bmi->bmiHeader.biBitCount); WARN("(%d): Unsupported depth\n", bmi->bmiHeader.biBitCount);
return; return;
} }
if (pix >= colors) { if (pix >= colors) {
WARN(bitmap, "pixel has color index greater than biClrUsed!\n"); WARN("pixel has color index greater than biClrUsed!\n");
return; return;
} }
if (loadflags & LR_LOADMAP3DCOLORS) c_W = c_F; if (loadflags & LR_LOADMAP3DCOLORS) c_W = c_F;

View File

@ -11,7 +11,7 @@
#include "wine/winestring.h" #include "wine/winestring.h"
#include "winerror.h" #include "winerror.h"
#include "enhmetafile.h" #include "enhmetafile.h"
#include "debug.h" #include "debugtools.h"
#include "heap.h" #include "heap.h"
DEFAULT_DEBUG_CHANNEL(enhmetafile) DEFAULT_DEBUG_CHANNEL(enhmetafile)
@ -59,7 +59,7 @@ static ENHMETAHEADER *EMF_GetEnhMetaHeader( HENHMETAFILE hmf )
{ {
ENHMETAFILEOBJ *metaObj = (ENHMETAFILEOBJ *)GDI_GetObjPtr( hmf, ENHMETAFILEOBJ *metaObj = (ENHMETAFILEOBJ *)GDI_GetObjPtr( hmf,
ENHMETAFILE_MAGIC ); ENHMETAFILE_MAGIC );
TRACE(enhmetafile, "hmf %04x -> enhmetaObj %p\n", hmf, metaObj); TRACE("hmf %04x -> enhmetaObj %p\n", hmf, metaObj);
return metaObj->emh; return metaObj->emh;
} }
@ -86,7 +86,7 @@ static HENHMETAFILE EMF_GetEnhMetaFile( HFILE hFile )
emh = MapViewOfFile( hMapping, FILE_MAP_READ, 0, 0, 0 ); emh = MapViewOfFile( hMapping, FILE_MAP_READ, 0, 0, 0 );
if (emh->iType != EMR_HEADER || emh->dSignature != ENHMETA_SIGNATURE) { if (emh->iType != EMR_HEADER || emh->dSignature != ENHMETA_SIGNATURE) {
WARN(enhmetafile, "Invalid emf header type 0x%08lx sig 0x%08lx.\n", WARN("Invalid emf header type 0x%08lx sig 0x%08lx.\n",
emh->iType, emh->dSignature); emh->iType, emh->dSignature);
UnmapViewOfFile( emh ); UnmapViewOfFile( emh );
CloseHandle( hMapping ); CloseHandle( hMapping );
@ -110,7 +110,7 @@ HENHMETAFILE WINAPI GetEnhMetaFileA(
hFile = CreateFileA(lpszMetaFile, GENERIC_READ, 0, 0, OPEN_EXISTING, 0, 0); hFile = CreateFileA(lpszMetaFile, GENERIC_READ, 0, 0, OPEN_EXISTING, 0, 0);
if (hFile == INVALID_HANDLE_VALUE) { if (hFile == INVALID_HANDLE_VALUE) {
WARN(enhmetafile,"could not open %s\n", lpszMetaFile); WARN("could not open %s\n", lpszMetaFile);
return 0; return 0;
} }
hmf = EMF_GetEnhMetaFile( hFile ); hmf = EMF_GetEnhMetaFile( hFile );
@ -130,7 +130,7 @@ HENHMETAFILE WINAPI GetEnhMetaFileW(
hFile = CreateFileW(lpszMetaFile, GENERIC_READ, 0, 0, OPEN_EXISTING, 0, 0); hFile = CreateFileW(lpszMetaFile, GENERIC_READ, 0, 0, OPEN_EXISTING, 0, 0);
if (hFile == INVALID_HANDLE_VALUE) { if (hFile == INVALID_HANDLE_VALUE) {
WARN(enhmetafile,"could not open %s\n", debugstr_w(lpszMetaFile)); WARN("could not open %s\n", debugstr_w(lpszMetaFile));
return 0; return 0;
} }
hmf = EMF_GetEnhMetaFile( hFile ); hmf = EMF_GetEnhMetaFile( hFile );
@ -268,14 +268,14 @@ BOOL WINAPI PlayEnhMetaFileRecord(
) )
{ {
int type; int type;
TRACE(enhmetafile, TRACE(
"hdc = %08x, handletable = %p, record = %p, numHandles = %d\n", "hdc = %08x, handletable = %p, record = %p, numHandles = %d\n",
hdc, handletable, mr, handles); hdc, handletable, mr, handles);
if (!mr) return FALSE; if (!mr) return FALSE;
type = mr->iType; type = mr->iType;
TRACE(enhmetafile, " type=%d\n", type); TRACE(" type=%d\n", type);
switch(type) switch(type)
{ {
case EMR_HEADER: case EMR_HEADER:
@ -402,7 +402,7 @@ BOOL WINAPI PlayEnhMetaFileRecord(
DWORD obj = mr->dParm[0]; DWORD obj = mr->dParm[0];
DWORD style = mr->dParm[1], brush = mr->dParm[2]; DWORD style = mr->dParm[1], brush = mr->dParm[2];
LOGBRUSH *b = (LOGBRUSH *) &mr->dParm[3]; LOGBRUSH *b = (LOGBRUSH *) &mr->dParm[3];
FIXME(enhmetafile, "Some ExtCreatePen args not handled\n"); FIXME("Some ExtCreatePen args not handled\n");
(handletable->objectHandle)[obj] = (handletable->objectHandle)[obj] =
ExtCreatePen(style, brush, b, 0, NULL); ExtCreatePen(style, brush, b, 0, NULL);
break; break;
@ -451,7 +451,7 @@ BOOL WINAPI PlayEnhMetaFileRecord(
{ {
/* 0-3 : a bounding rectangle? */ /* 0-3 : a bounding rectangle? */
INT count = mr->dParm[4]; INT count = mr->dParm[4];
FIXME(enhmetafile, "Some Polygon16 args not handled\n"); FIXME("Some Polygon16 args not handled\n");
Polygon16(hdc, (POINT16 *)&mr->dParm[5], count); Polygon16(hdc, (POINT16 *)&mr->dParm[5], count);
break; break;
} }
@ -459,7 +459,7 @@ BOOL WINAPI PlayEnhMetaFileRecord(
{ {
/* 0-3 : a bounding rectangle? */ /* 0-3 : a bounding rectangle? */
INT count = mr->dParm[4]; INT count = mr->dParm[4];
FIXME(enhmetafile, "Some Polyline16 args not handled\n"); FIXME("Some Polyline16 args not handled\n");
Polyline16(hdc, (POINT16 *)&mr->dParm[5], count); Polyline16(hdc, (POINT16 *)&mr->dParm[5], count);
break; break;
} }
@ -506,14 +506,14 @@ BOOL WINAPI PlayEnhMetaFileRecord(
/* 10-16: ??? */ /* 10-16: ??? */
LPWSTR str = (LPWSTR)& mr->dParm[17]; LPWSTR str = (LPWSTR)& mr->dParm[17];
/* trailing info: dx array? */ /* trailing info: dx array? */
FIXME(enhmetafile, "Many ExtTextOut args not handled\n"); FIXME("Many ExtTextOut args not handled\n");
ExtTextOutW(hdc, x, y, flags, /* lpRect */ NULL, ExtTextOutW(hdc, x, y, flags, /* lpRect */ NULL,
str, count, /* lpDx */ NULL); str, count, /* lpDx */ NULL);
break; break;
} }
default: default:
FIXME(enhmetafile, "type %d is unimplemented\n", type); FIXME("type %d is unimplemented\n", type);
/* SetLastError(E_NOTIMPL); */ /* SetLastError(E_NOTIMPL); */
break; break;
} }
@ -598,10 +598,10 @@ BOOL WINAPI PlayEnhMetaFile(
xform.eM22 = yscale; xform.eM22 = yscale;
xform.eDx = lpRect->left; xform.eDx = lpRect->left;
xform.eDy = lpRect->top; xform.eDy = lpRect->top;
FIXME(enhmetafile, "play into rect doesn't work\n"); FIXME("play into rect doesn't work\n");
savedMode = SetGraphicsMode(hdc, GM_ADVANCED); savedMode = SetGraphicsMode(hdc, GM_ADVANCED);
if (!SetWorldTransform(hdc, &xform)) { if (!SetWorldTransform(hdc, &xform)) {
WARN(enhmetafile, "World transform failed!\n"); WARN("World transform failed!\n");
} }
} }
@ -682,7 +682,7 @@ HENHMETAFILE WINAPI SetWinMetaFileBits(UINT cbBuffer,
CONST METAFILEPICT *lpmfp CONST METAFILEPICT *lpmfp
) )
{ {
FIXME(enhmetafile,"Stub\n"); FIXME("Stub\n");
return 0; return 0;
} }

View File

@ -21,7 +21,7 @@
#include "palette.h" #include "palette.h"
#include "pen.h" #include "pen.h"
#include "region.h" #include "region.h"
#include "debug.h" #include "debugtools.h"
#include "gdi.h" #include "gdi.h"
DEFAULT_DEBUG_CHANNEL(gdi) DEFAULT_DEBUG_CHANNEL(gdi)
@ -368,7 +368,7 @@ BOOL WINAPI DeleteObject( HGDIOBJ obj )
return TRUE; return TRUE;
if (!(header = (GDIOBJHDR *) GDI_HEAP_LOCK( obj ))) return FALSE; if (!(header = (GDIOBJHDR *) GDI_HEAP_LOCK( obj ))) return FALSE;
TRACE(gdi, "%04x\n", obj ); TRACE("%04x\n", obj );
/* Delete object */ /* Delete object */
@ -382,10 +382,10 @@ BOOL WINAPI DeleteObject( HGDIOBJ obj )
case REGION_MAGIC: return REGION_DeleteObject( obj, (RGNOBJ*)header ); case REGION_MAGIC: return REGION_DeleteObject( obj, (RGNOBJ*)header );
case DC_MAGIC: return DeleteDC(obj); case DC_MAGIC: return DeleteDC(obj);
case 0 : case 0 :
WARN(gdi, "Already deleted\n"); WARN("Already deleted\n");
break; break;
default: default:
WARN(gdi, "Unknown magic number (%d)\n",header->wMagic); WARN("Unknown magic number (%d)\n",header->wMagic);
} }
return FALSE; return FALSE;
} }
@ -406,7 +406,7 @@ HGDIOBJ WINAPI GetStockObject( INT obj )
{ {
if ((obj < 0) || (obj >= NB_STOCK_OBJECTS)) return 0; if ((obj < 0) || (obj >= NB_STOCK_OBJECTS)) return 0;
if (!StockObjects[obj]) return 0; if (!StockObjects[obj]) return 0;
TRACE(gdi, "returning %d\n", TRACE("returning %d\n",
FIRST_STOCK_HANDLE + obj ); FIRST_STOCK_HANDLE + obj );
return (HGDIOBJ16)(FIRST_STOCK_HANDLE + obj); return (HGDIOBJ16)(FIRST_STOCK_HANDLE + obj);
} }
@ -419,7 +419,7 @@ INT16 WINAPI GetObject16( HANDLE16 handle, INT16 count, LPVOID buffer )
{ {
GDIOBJHDR * ptr = NULL; GDIOBJHDR * ptr = NULL;
INT16 result = 0; INT16 result = 0;
TRACE(gdi, "%04x %d %p\n", handle, count, buffer ); TRACE("%04x %d %p\n", handle, count, buffer );
if (!count) return 0; if (!count) return 0;
if ((handle >= FIRST_STOCK_HANDLE) && (handle <= LAST_STOCK_HANDLE)) if ((handle >= FIRST_STOCK_HANDLE) && (handle <= LAST_STOCK_HANDLE))
@ -458,7 +458,7 @@ INT WINAPI GetObjectA( HANDLE handle, INT count, LPVOID buffer )
{ {
GDIOBJHDR * ptr = NULL; GDIOBJHDR * ptr = NULL;
INT result = 0; INT result = 0;
TRACE(gdi, "%08x %d %p\n", handle, count, buffer ); TRACE("%08x %d %p\n", handle, count, buffer );
if (!count) return 0; if (!count) return 0;
if ((handle >= FIRST_STOCK_HANDLE) && (handle <= LAST_STOCK_HANDLE)) if ((handle >= FIRST_STOCK_HANDLE) && (handle <= LAST_STOCK_HANDLE))
@ -485,7 +485,7 @@ INT WINAPI GetObjectA( HANDLE handle, INT count, LPVOID buffer )
result = PALETTE_GetObject( (PALETTEOBJ *)ptr, count, buffer ); result = PALETTE_GetObject( (PALETTEOBJ *)ptr, count, buffer );
break; break;
default: default:
FIXME(gdi, "Magic %04x not implemented\n", FIXME("Magic %04x not implemented\n",
ptr->wMagic ); ptr->wMagic );
break; break;
} }
@ -499,7 +499,7 @@ INT WINAPI GetObjectW( HANDLE handle, INT count, LPVOID buffer )
{ {
GDIOBJHDR * ptr = NULL; GDIOBJHDR * ptr = NULL;
INT result = 0; INT result = 0;
TRACE(gdi, "%08x %d %p\n", handle, count, buffer ); TRACE("%08x %d %p\n", handle, count, buffer );
if (!count) return 0; if (!count) return 0;
if ((handle >= FIRST_STOCK_HANDLE) && (handle <= LAST_STOCK_HANDLE)) if ((handle >= FIRST_STOCK_HANDLE) && (handle <= LAST_STOCK_HANDLE))
@ -526,7 +526,7 @@ INT WINAPI GetObjectW( HANDLE handle, INT count, LPVOID buffer )
result = PALETTE_GetObject( (PALETTEOBJ *)ptr, count, buffer ); result = PALETTE_GetObject( (PALETTEOBJ *)ptr, count, buffer );
break; break;
default: default:
FIXME(gdi, "Magic %04x not implemented\n", FIXME("Magic %04x not implemented\n",
ptr->wMagic ); ptr->wMagic );
break; break;
} }
@ -541,7 +541,7 @@ DWORD WINAPI GetObjectType( HANDLE handle )
{ {
GDIOBJHDR * ptr = NULL; GDIOBJHDR * ptr = NULL;
INT result = 0; INT result = 0;
TRACE(gdi, "%08x\n", handle ); TRACE("%08x\n", handle );
if ((handle >= FIRST_STOCK_HANDLE) && (handle <= LAST_STOCK_HANDLE)) if ((handle >= FIRST_STOCK_HANDLE) && (handle <= LAST_STOCK_HANDLE))
ptr = StockObjects[handle - FIRST_STOCK_HANDLE]; ptr = StockObjects[handle - FIRST_STOCK_HANDLE];
@ -588,7 +588,7 @@ DWORD WINAPI GetObjectType( HANDLE handle )
result = OBJ_ENHMETADC; result = OBJ_ENHMETADC;
break; break;
default: default:
FIXME(gdi, "Magic %04x not implemented\n", FIXME("Magic %04x not implemented\n",
ptr->wMagic ); ptr->wMagic );
break; break;
} }
@ -613,7 +613,7 @@ HANDLE WINAPI GetCurrentObject(HDC hdc,UINT type)
case OBJ_BITMAP: return dc->w.hBitmap; case OBJ_BITMAP: return dc->w.hBitmap;
default: default:
/* the SDK only mentions those above */ /* the SDK only mentions those above */
WARN(gdi,"(%08x,%d): unknown type.\n",hdc,type); WARN("(%08x,%d): unknown type.\n",hdc,type);
return 0; return 0;
} }
} }
@ -635,7 +635,7 @@ HGDIOBJ WINAPI SelectObject( HDC hdc, HGDIOBJ handle )
{ {
DC * dc = DC_GetDCPtr( hdc ); DC * dc = DC_GetDCPtr( hdc );
if (!dc || !dc->funcs->pSelectObject) return 0; if (!dc || !dc->funcs->pSelectObject) return 0;
TRACE(gdi, "hdc=%04x %04x\n", hdc, handle ); TRACE("hdc=%04x %04x\n", hdc, handle );
return dc->funcs->pSelectObject( dc, handle ); return dc->funcs->pSelectObject( dc, handle );
} }
@ -660,7 +660,7 @@ BOOL WINAPI UnrealizeObject( HGDIOBJ obj )
GDIOBJHDR * header = (GDIOBJHDR *) GDI_HEAP_LOCK( obj ); GDIOBJHDR * header = (GDIOBJHDR *) GDI_HEAP_LOCK( obj );
if (!header) return FALSE; if (!header) return FALSE;
TRACE(gdi, "%04x\n", obj ); TRACE("%04x\n", obj );
/* Unrealize object */ /* Unrealize object */
@ -701,7 +701,7 @@ INT16 WINAPI EnumObjects16( HDC16 hdc, INT16 nObjType,
LOGPEN16 *pen; LOGPEN16 *pen;
LOGBRUSH16 *brush = NULL; LOGBRUSH16 *brush = NULL;
TRACE(gdi, "%04x %d %08lx %08lx\n", TRACE("%04x %d %08lx %08lx\n",
hdc, nObjType, (DWORD)lpEnumFunc, lParam ); hdc, nObjType, (DWORD)lpEnumFunc, lParam );
switch(nObjType) switch(nObjType)
{ {
@ -715,7 +715,7 @@ INT16 WINAPI EnumObjects16( HDC16 hdc, INT16 nObjType,
pen->lopnWidth.y = 0; pen->lopnWidth.y = 0;
pen->lopnColor = solid_colors[i]; pen->lopnColor = solid_colors[i];
retval = lpEnumFunc( SEGPTR_GET(pen), lParam ); retval = lpEnumFunc( SEGPTR_GET(pen), lParam );
TRACE(gdi, "solid pen %08lx, ret=%d\n", TRACE("solid pen %08lx, ret=%d\n",
solid_colors[i], retval); solid_colors[i], retval);
if (!retval) break; if (!retval) break;
} }
@ -731,7 +731,7 @@ INT16 WINAPI EnumObjects16( HDC16 hdc, INT16 nObjType,
brush->lbColor = solid_colors[i]; brush->lbColor = solid_colors[i];
brush->lbHatch = 0; brush->lbHatch = 0;
retval = lpEnumFunc( SEGPTR_GET(brush), lParam ); retval = lpEnumFunc( SEGPTR_GET(brush), lParam );
TRACE(gdi, "solid brush %08lx, ret=%d\n", TRACE("solid brush %08lx, ret=%d\n",
solid_colors[i], retval); solid_colors[i], retval);
if (!retval) break; if (!retval) break;
} }
@ -743,7 +743,7 @@ INT16 WINAPI EnumObjects16( HDC16 hdc, INT16 nObjType,
brush->lbColor = RGB(0,0,0); brush->lbColor = RGB(0,0,0);
brush->lbHatch = i; brush->lbHatch = i;
retval = lpEnumFunc( SEGPTR_GET(brush), lParam ); retval = lpEnumFunc( SEGPTR_GET(brush), lParam );
TRACE(gdi, "hatched brush %d, ret=%d\n", TRACE("hatched brush %d, ret=%d\n",
i, retval); i, retval);
if (!retval) break; if (!retval) break;
} }
@ -751,7 +751,7 @@ INT16 WINAPI EnumObjects16( HDC16 hdc, INT16 nObjType,
break; break;
default: default:
WARN(gdi, "(%d): Invalid type\n", nObjType ); WARN("(%d): Invalid type\n", nObjType );
break; break;
} }
return retval; return retval;
@ -780,7 +780,7 @@ INT WINAPI EnumObjects( HDC hdc, INT nObjType,
LOGPEN pen; LOGPEN pen;
LOGBRUSH brush; LOGBRUSH brush;
TRACE(gdi, "%04x %d %08lx %08lx\n", TRACE("%04x %d %08lx %08lx\n",
hdc, nObjType, (DWORD)lpEnumFunc, lParam ); hdc, nObjType, (DWORD)lpEnumFunc, lParam );
switch(nObjType) switch(nObjType)
{ {
@ -793,7 +793,7 @@ INT WINAPI EnumObjects( HDC hdc, INT nObjType,
pen.lopnWidth.y = 0; pen.lopnWidth.y = 0;
pen.lopnColor = solid_colors[i]; pen.lopnColor = solid_colors[i];
retval = lpEnumFunc( &pen, lParam ); retval = lpEnumFunc( &pen, lParam );
TRACE(gdi, "solid pen %08lx, ret=%d\n", TRACE("solid pen %08lx, ret=%d\n",
solid_colors[i], retval); solid_colors[i], retval);
if (!retval) break; if (!retval) break;
} }
@ -807,7 +807,7 @@ INT WINAPI EnumObjects( HDC hdc, INT nObjType,
brush.lbColor = solid_colors[i]; brush.lbColor = solid_colors[i];
brush.lbHatch = 0; brush.lbHatch = 0;
retval = lpEnumFunc( &brush, lParam ); retval = lpEnumFunc( &brush, lParam );
TRACE(gdi, "solid brush %08lx, ret=%d\n", TRACE("solid brush %08lx, ret=%d\n",
solid_colors[i], retval); solid_colors[i], retval);
if (!retval) break; if (!retval) break;
} }
@ -819,7 +819,7 @@ INT WINAPI EnumObjects( HDC hdc, INT nObjType,
brush.lbColor = RGB(0,0,0); brush.lbColor = RGB(0,0,0);
brush.lbHatch = i; brush.lbHatch = i;
retval = lpEnumFunc( &brush, lParam ); retval = lpEnumFunc( &brush, lParam );
TRACE(gdi, "hatched brush %d, ret=%d\n", TRACE("hatched brush %d, ret=%d\n",
i, retval); i, retval);
if (!retval) break; if (!retval) break;
} }
@ -827,7 +827,7 @@ INT WINAPI EnumObjects( HDC hdc, INT nObjType,
default: default:
/* FIXME: implement Win32 types */ /* FIXME: implement Win32 types */
WARN( gdi, "(%d): Invalid type\n", nObjType ); WARN("(%d): Invalid type\n", nObjType );
break; break;
} }
return retval; return retval;
@ -964,7 +964,7 @@ DWORD WINAPI GdiSeeGdiDo16( WORD wReqType, WORD wParam1, WORD wParam2,
case 0x0103: /* LocalHeap */ case 0x0103: /* LocalHeap */
return GDI_HeapSel; return GDI_HeapSel;
default: default:
WARN(gdi, "(wReqType=%04x): Unknown\n", wReqType); WARN("(wReqType=%04x): Unknown\n", wReqType);
return (DWORD)-1; return (DWORD)-1;
} }
} }
@ -1030,7 +1030,7 @@ INT WINAPI MulDiv(
*/ */
BOOL WINAPI GetColorAdjustment(HDC hdc, LPCOLORADJUSTMENT lpca) BOOL WINAPI GetColorAdjustment(HDC hdc, LPCOLORADJUSTMENT lpca)
{ {
FIXME(gdi, "GetColorAdjustment, stub\n"); FIXME("GetColorAdjustment, stub\n");
return 0; return 0;
} }
@ -1041,7 +1041,7 @@ BOOL WINAPI GetColorAdjustment(HDC hdc, LPCOLORADJUSTMENT lpca)
*/ */
BOOL WINAPI GetMiterLimit(HDC hdc, PFLOAT peLimit) BOOL WINAPI GetMiterLimit(HDC hdc, PFLOAT peLimit)
{ {
FIXME(gdi, "GetMiterLimit, stub\n"); FIXME("GetMiterLimit, stub\n");
return 0; return 0;
} }
@ -1052,7 +1052,7 @@ BOOL WINAPI GetMiterLimit(HDC hdc, PFLOAT peLimit)
*/ */
BOOL WINAPI SetMiterLimit(HDC hdc, FLOAT eNewLimit, PFLOAT peOldLimit) BOOL WINAPI SetMiterLimit(HDC hdc, FLOAT eNewLimit, PFLOAT peOldLimit)
{ {
FIXME(gdi, "SetMiterLimit, stub\n"); FIXME("SetMiterLimit, stub\n");
return 0; return 0;
} }
@ -1063,7 +1063,7 @@ BOOL WINAPI SetMiterLimit(HDC hdc, FLOAT eNewLimit, PFLOAT peOldLimit)
*/ */
BOOL WINAPI GdiComment(HDC hdc, UINT cbSize, const BYTE *lpData) BOOL WINAPI GdiComment(HDC hdc, UINT cbSize, const BYTE *lpData)
{ {
FIXME(gdi, "GdiComment, stub\n"); FIXME("GdiComment, stub\n");
return 0; return 0;
} }
/******************************************************************* /*******************************************************************
@ -1073,7 +1073,7 @@ BOOL WINAPI GdiComment(HDC hdc, UINT cbSize, const BYTE *lpData)
*/ */
BOOL WINAPI SetColorAdjustment(HDC hdc, const COLORADJUSTMENT* lpca) BOOL WINAPI SetColorAdjustment(HDC hdc, const COLORADJUSTMENT* lpca)
{ {
FIXME(gdi, "SetColorAdjustment, stub\n"); FIXME("SetColorAdjustment, stub\n");
return 0; return 0;
} }

View File

@ -38,7 +38,7 @@
#include "bitmap.h" #include "bitmap.h"
#include "heap.h" #include "heap.h"
#include "toolhelp.h" #include "toolhelp.h"
#include "debug.h" #include "debugtools.h"
#include "global.h" #include "global.h"
DEFAULT_DEBUG_CHANNEL(metafile) DEFAULT_DEBUG_CHANNEL(metafile)
@ -201,7 +201,7 @@ static METAHEADER *MF_ReadMetaFile(HFILE hfile)
} }
if (mh->mtType != METAFILE_MEMORY) { if (mh->mtType != METAFILE_MEMORY) {
WARN(metafile, "Disk metafile had mtType = %04x\n", mh->mtType); WARN("Disk metafile had mtType = %04x\n", mh->mtType);
mh->mtType = METAFILE_MEMORY; mh->mtType = METAFILE_MEMORY;
} }
return mh; return mh;
@ -215,7 +215,7 @@ HMETAFILE16 WINAPI GetMetaFile16( LPCSTR lpFilename )
METAHEADER *mh; METAHEADER *mh;
HFILE hFile; HFILE hFile;
TRACE(metafile,"%s\n", lpFilename); TRACE("%s\n", lpFilename);
if(!lpFilename) if(!lpFilename)
return 0; return 0;
@ -240,7 +240,7 @@ HMETAFILE WINAPI GetMetaFileA( LPCSTR lpFilename )
METAHEADER *mh; METAHEADER *mh;
HFILE hFile; HFILE hFile;
TRACE(metafile,"%s\n", lpFilename); TRACE("%s\n", lpFilename);
if(!lpFilename) if(!lpFilename)
return 0; return 0;
@ -265,7 +265,7 @@ HMETAFILE WINAPI GetMetaFileW( LPCWSTR lpFilename )
METAHEADER *mh; METAHEADER *mh;
HFILE hFile; HFILE hFile;
TRACE(metafile,"%s\n", debugstr_w(lpFilename)); TRACE("%s\n", debugstr_w(lpFilename));
if(!lpFilename) if(!lpFilename)
return 0; return 0;
@ -293,14 +293,14 @@ static METAHEADER *MF_LoadDiskBasedMetaFile(METAHEADER *mh)
METAHEADER *mh2; METAHEADER *mh2;
if(mh->mtType != METAFILE_DISK) { if(mh->mtType != METAFILE_DISK) {
ERR(metafile, "Not a disk based metafile\n"); ERR("Not a disk based metafile\n");
return NULL; return NULL;
} }
mhd = (METAHEADERDISK *)((char *)mh + sizeof(METAHEADER)); mhd = (METAHEADERDISK *)((char *)mh + sizeof(METAHEADER));
if((hfile = CreateFileA(mhd->filename, GENERIC_READ, 0, NULL, if((hfile = CreateFileA(mhd->filename, GENERIC_READ, 0, NULL,
OPEN_EXISTING, 0, -1)) == HFILE_ERROR) { OPEN_EXISTING, 0, -1)) == HFILE_ERROR) {
WARN(metafile, "Can't open file of disk based metafile\n"); WARN("Can't open file of disk based metafile\n");
return NULL; return NULL;
} }
mh2 = MF_ReadMetaFile(hfile); mh2 = MF_ReadMetaFile(hfile);
@ -337,7 +337,7 @@ HMETAFILE16 WINAPI CopyMetaFile16( HMETAFILE16 hSrcMetaFile, LPCSTR lpFilename)
METAHEADER *mh2 = NULL; METAHEADER *mh2 = NULL;
HFILE hFile; HFILE hFile;
TRACE(metafile,"(%08x,%s)\n", hSrcMetaFile, lpFilename); TRACE("(%08x,%s)\n", hSrcMetaFile, lpFilename);
if(!mh) return 0; if(!mh) return 0;
@ -387,7 +387,7 @@ HMETAFILE WINAPI CopyMetaFileA(
METAHEADER *mh2 = NULL; METAHEADER *mh2 = NULL;
HFILE hFile; HFILE hFile;
TRACE(metafile,"(%08x,%s)\n", hSrcMetaFile, lpFilename); TRACE("(%08x,%s)\n", hSrcMetaFile, lpFilename);
if(!mh) return 0; if(!mh) return 0;
@ -452,7 +452,7 @@ BOOL16 WINAPI IsValidMetaFile16(HMETAFILE16 hmf)
res=TRUE; res=TRUE;
MF_ReleaseMetaHeader16(hmf); MF_ReleaseMetaHeader16(hmf);
} }
TRACE(metafile,"IsValidMetaFile %x => %d\n",hmf,res); TRACE("IsValidMetaFile %x => %d\n",hmf,res);
return res; return res;
} }
@ -498,10 +498,10 @@ static BOOL MF_PlayMetaFile( HDC hdc, METAHEADER *mh)
while (offset < mh->mtSize * 2) while (offset < mh->mtSize * 2)
{ {
mr = (METARECORD *)((char *)mh + offset); mr = (METARECORD *)((char *)mh + offset);
TRACE(metafile,"offset=%04x,size=%08lx\n", TRACE("offset=%04x,size=%08lx\n",
offset, mr->rdSize); offset, mr->rdSize);
if (!mr->rdSize) { if (!mr->rdSize) {
TRACE(metafile, TRACE(
"Entry got size 0 at offset %d, total mf length is %ld\n", "Entry got size 0 at offset %d, total mf length is %ld\n",
offset,mh->mtSize*2); offset,mh->mtSize*2);
break; /* would loop endlessly otherwise */ break; /* would loop endlessly otherwise */
@ -578,7 +578,7 @@ BOOL16 WINAPI EnumMetaFile16( HDC16 hdc, HMETAFILE16 hmf,
DC *dc; DC *dc;
BOOL16 result = TRUE, loaded = FALSE; BOOL16 result = TRUE, loaded = FALSE;
TRACE(metafile,"(%04x, %04x, %08lx, %08lx)\n", TRACE("(%04x, %04x, %08lx, %08lx)\n",
hdc, hmf, (DWORD)lpEnumFunc, lpData); hdc, hmf, (DWORD)lpEnumFunc, lpData);
@ -670,7 +670,7 @@ BOOL WINAPI EnumMetaFile(
HBRUSH hBrush; HBRUSH hBrush;
HFONT hFont; HFONT hFont;
TRACE(metafile,"(%08x,%08x,%p,%p)\n", TRACE("(%08x,%08x,%p,%p)\n",
hdc, hmf, lpEnumFunc, (void*)lpData); hdc, hmf, lpEnumFunc, (void*)lpData);
if (!mh) return 0; if (!mh) return 0;
if(mh->mtType == METAFILE_DISK) { /* Create a memoery-based copy */ if(mh->mtType == METAFILE_DISK) { /* Create a memoery-based copy */
@ -696,7 +696,7 @@ BOOL WINAPI EnumMetaFile(
while (offset < (mh->mtSize * 2)) while (offset < (mh->mtSize * 2))
{ {
mr = (METARECORD *)((char *)mh + offset); mr = (METARECORD *)((char *)mh + offset);
TRACE(metafile, "Calling EnumFunc with record type %x\n", TRACE("Calling EnumFunc with record type %x\n",
mr->rdFunction); mr->rdFunction);
if (!lpEnumFunc( hdc, ht, mr, mh->mtNoObjects, (LONG)lpData )) if (!lpEnumFunc( hdc, ht, mr, mh->mtNoObjects, (LONG)lpData ))
{ {
@ -753,7 +753,7 @@ void WINAPI PlayMetaFileRecord16(
char *ptr; char *ptr;
BITMAPINFOHEADER *infohdr; BITMAPINFOHEADER *infohdr;
TRACE(metafile,"(%04x %08lx %08lx %04x) function %04x\n", TRACE("(%04x %08lx %08lx %04x) function %04x\n",
hdc,(LONG)ht, (LONG)mr, nHandles, mr->rdFunction); hdc,(LONG)ht, (LONG)mr, nHandles, mr->rdFunction);
switch (mr->rdFunction) switch (mr->rdFunction)
@ -965,7 +965,7 @@ void WINAPI PlayMetaFileRecord16(
break; break;
default: default:
ERR(metafile, "META_CREATEPATTERNBRUSH: Unknown pattern type %d\n", ERR("META_CREATEPATTERNBRUSH: Unknown pattern type %d\n",
mr->rdParm[0]); mr->rdParm[0]);
break; break;
} }
@ -1009,7 +1009,7 @@ void WINAPI PlayMetaFileRecord16(
break; break;
case META_ESCAPE: case META_ESCAPE:
FIXME(metafile, "META_ESCAPE unimplemented.\n"); FIXME("META_ESCAPE unimplemented.\n");
break; break;
case META_EXTTEXTOUT: case META_EXTTEXTOUT:
@ -1109,7 +1109,7 @@ void WINAPI PlayMetaFileRecord16(
/* *(mr->rdParm) may be BS_PATTERN or BS_DIBPATTERN: /* *(mr->rdParm) may be BS_PATTERN or BS_DIBPATTERN:
but there's no difference */ but there's no difference */
TRACE(metafile,"%d\n",*(mr->rdParm)); TRACE("%d\n",*(mr->rdParm));
s1 = mr->rdSize * 2 - sizeof(METARECORD) - 2; s1 = mr->rdSize * 2 - sizeof(METARECORD) - 2;
hndl = GlobalAlloc16(GMEM_MOVEABLE, s1); hndl = GlobalAlloc16(GMEM_MOVEABLE, s1);
ptr = GlobalLock16(hndl); ptr = GlobalLock16(hndl);
@ -1172,7 +1172,7 @@ void WINAPI PlayMetaFileRecord16(
} }
#define META_UNIMP(x) case x: \ #define META_UNIMP(x) case x: \
FIXME(metafile, "PlayMetaFileRecord:record type "#x" not implemented.\n"); \ FIXME("PlayMetaFileRecord:record type "#x" not implemented.\n"); \
break; break;
META_UNIMP(META_DRAWTEXT) META_UNIMP(META_DRAWTEXT)
META_UNIMP(META_ANIMATEPALETTE) META_UNIMP(META_ANIMATEPALETTE)
@ -1190,7 +1190,7 @@ break;
#undef META_UNIMP #undef META_UNIMP
default: default:
WARN(metafile, "PlayMetaFileRecord: Unknown record type %x\n", WARN("PlayMetaFileRecord: Unknown record type %x\n",
mr->rdFunction); mr->rdFunction);
} }
} }
@ -1204,7 +1204,7 @@ BOOL WINAPI PlayMetaFileRecord( HDC hdc, HANDLETABLE *handletable,
HANDLETABLE16 * ht = (void *)GlobalAlloc(GPTR, HANDLETABLE16 * ht = (void *)GlobalAlloc(GPTR,
handles*sizeof(HANDLETABLE16)); handles*sizeof(HANDLETABLE16));
int i = 0; int i = 0;
TRACE(metafile, "(%08x,%p,%p,%d)\n", hdc, handletable, metarecord, TRACE("(%08x,%p,%p,%d)\n", hdc, handletable, metarecord,
handles); handles);
for (i=0; i<handles; i++) for (i=0; i<handles; i++)
ht->objectHandle[i] = handletable->objectHandle[i]; ht->objectHandle[i] = handletable->objectHandle[i];
@ -1226,7 +1226,7 @@ HGLOBAL16 WINAPI GetMetaFileBits16(
HMETAFILE16 hmf /* metafile handle */ HMETAFILE16 hmf /* metafile handle */
) )
{ {
TRACE(metafile,"hMem out: %04x\n", hmf); TRACE("hMem out: %04x\n", hmf);
return hmf; return hmf;
} }
@ -1243,7 +1243,7 @@ HMETAFILE16 WINAPI SetMetaFileBits16(
/* handle to a memory region holding a metafile */ /* handle to a memory region holding a metafile */
) )
{ {
TRACE(metafile,"hmf out: %04x\n", hMem); TRACE("hmf out: %04x\n", hMem);
return hMem; return hMem;
} }
@ -1298,14 +1298,14 @@ UINT WINAPI GetMetaFileBitsEx(
METAHEADER *mh = MF_GetMetaHeader(hmf); METAHEADER *mh = MF_GetMetaHeader(hmf);
UINT mfSize; UINT mfSize;
TRACE(metafile, "(%08x,%d,%p)\n", hmf, nSize, buf); TRACE("(%08x,%d,%p)\n", hmf, nSize, buf);
if (!mh) return 0; /* FIXME: error code */ if (!mh) return 0; /* FIXME: error code */
if(mh->mtType == METAFILE_DISK) if(mh->mtType == METAFILE_DISK)
FIXME(metafile, "Disk-based metafile?\n"); FIXME("Disk-based metafile?\n");
mfSize = mh->mtSize * 2; mfSize = mh->mtSize * 2;
if (!buf) { if (!buf) {
MF_ReleaseMetaHeader(hmf); MF_ReleaseMetaHeader(hmf);
TRACE(metafile,"returning size %d\n", mfSize); TRACE("returning size %d\n", mfSize);
return mfSize; return mfSize;
} }
if(mfSize > nSize) mfSize = nSize; if(mfSize > nSize) mfSize = nSize;
@ -1321,7 +1321,7 @@ UINT WINAPI GetWinMetaFileBits(HENHMETAFILE hemf,
UINT cbBuffer, LPBYTE lpbBuffer, UINT cbBuffer, LPBYTE lpbBuffer,
INT fnMapMode, HDC hdcRef) INT fnMapMode, HDC hdcRef)
{ {
FIXME(metafile, "(%d,%d,%p,%d,%d): stub\n", FIXME("(%d,%d,%p,%d,%d): stub\n",
hemf, cbBuffer, lpbBuffer, fnMapMode, hdcRef); hemf, cbBuffer, lpbBuffer, fnMapMode, hdcRef);
return 0; return 0;
} }
@ -1368,20 +1368,20 @@ static BOOL MF_Play_MetaCreateRegion( METARECORD *mr, HRGN hrgn )
for(band = 0, start = &(mr->rdParm[11]); band < mr->rdParm[5]; for(band = 0, start = &(mr->rdParm[11]); band < mr->rdParm[5];
band++, start = end + 1) { band++, start = end + 1) {
if(*start / 2 != (*start + 1) / 2) { if(*start / 2 != (*start + 1) / 2) {
WARN(metafile, "Delimiter not even.\n"); WARN("Delimiter not even.\n");
DeleteObject( hrgn2 ); DeleteObject( hrgn2 );
return FALSE; return FALSE;
} }
end = start + *start + 3; end = start + *start + 3;
if(end > (WORD *)mr + mr->rdSize) { if(end > (WORD *)mr + mr->rdSize) {
WARN(metafile, "End points outside record.\n"); WARN("End points outside record.\n");
DeleteObject( hrgn2 ); DeleteObject( hrgn2 );
return FALSE; return FALSE;
} }
if(*start != *end) { if(*start != *end) {
WARN(metafile, "Mismatched delimiters.\n"); WARN("Mismatched delimiters.\n");
DeleteObject( hrgn2 ); DeleteObject( hrgn2 );
return FALSE; return FALSE;
} }
@ -1427,8 +1427,8 @@ static BOOL MF_Play_MetaExtTextOut(HDC16 hdc, METARECORD *mr)
if (mr->rdSize == (len + s1 * sizeof(INT16)) / 2) if (mr->rdSize == (len + s1 * sizeof(INT16)) / 2)
dxx = (LPINT16)(sot+(((s1+1)>>1)*2)); dxx = (LPINT16)(sot+(((s1+1)>>1)*2));
else { else {
TRACE(metafile,"%s len: %ld\n", sot, mr->rdSize); TRACE("%s len: %ld\n", sot, mr->rdSize);
WARN(metafile, WARN(
"Please report: ExtTextOut len=%ld slen=%d rdSize=%ld opt=%04x\n", "Please report: ExtTextOut len=%ld slen=%d rdSize=%ld opt=%04x\n",
len, s1, mr->rdSize, mr->rdParm[3]); len, s1, mr->rdSize, mr->rdParm[3]);
dxx = NULL; /* should't happen -- but if, we continue with NULL */ dxx = NULL; /* should't happen -- but if, we continue with NULL */
@ -1441,6 +1441,6 @@ static BOOL MF_Play_MetaExtTextOut(HDC16 hdc, METARECORD *mr)
sot, /* string */ sot, /* string */
s1, dxx); /* length, dx array */ s1, dxx); /* length, dx array */
if (dxx) if (dxx)
TRACE(metafile,"%s len: %ld dx0: %d\n", sot, mr->rdSize, dxx[0]); TRACE("%s len: %ld dx0: %d\n", sot, mr->rdSize, dxx[0]);
return TRUE; return TRUE;
} }

View File

@ -17,7 +17,7 @@
#include "color.h" #include "color.h"
#include "palette.h" #include "palette.h"
#include "xmalloc.h" #include "xmalloc.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(palette) DEFAULT_DEBUG_CHANNEL(palette)
@ -110,7 +110,7 @@ HPALETTE WINAPI CreatePalette(
int size; int size;
if (!palette) return 0; if (!palette) return 0;
TRACE(palette,"entries=%i\n", palette->palNumEntries); TRACE("entries=%i\n", palette->palNumEntries);
size = sizeof(LOGPALETTE) + (palette->palNumEntries - 1) * sizeof(PALETTEENTRY); size = sizeof(LOGPALETTE) + (palette->palNumEntries - 1) * sizeof(PALETTEENTRY);
@ -124,7 +124,7 @@ HPALETTE WINAPI CreatePalette(
palettePtr->mapping = NULL; palettePtr->mapping = NULL;
GDI_HEAP_UNLOCK( hpalette ); GDI_HEAP_UNLOCK( hpalette );
TRACE(palette," returning %04x\n", hpalette); TRACE(" returning %04x\n", hpalette);
return hpalette; return hpalette;
} }
@ -215,7 +215,7 @@ UINT WINAPI GetPaletteEntries(
PALETTEOBJ * palPtr; PALETTEOBJ * palPtr;
INT numEntries; INT numEntries;
TRACE(palette,"hpal = %04x, count=%i\n", hpalette, count ); TRACE("hpal = %04x, count=%i\n", hpalette, count );
palPtr = (PALETTEOBJ *) GDI_GetObjPtr( hpalette, PALETTE_MAGIC ); palPtr = (PALETTEOBJ *) GDI_GetObjPtr( hpalette, PALETTE_MAGIC );
if (!palPtr) return 0; if (!palPtr) return 0;
@ -267,7 +267,7 @@ UINT WINAPI SetPaletteEntries(
PALETTEOBJ * palPtr; PALETTEOBJ * palPtr;
INT numEntries; INT numEntries;
TRACE(palette,"hpal=%04x,start=%i,count=%i\n",hpalette,start,count ); TRACE("hpal=%04x,start=%i,count=%i\n",hpalette,start,count );
palPtr = (PALETTEOBJ *) GDI_GetObjPtr( hpalette, PALETTE_MAGIC ); palPtr = (PALETTEOBJ *) GDI_GetObjPtr( hpalette, PALETTE_MAGIC );
if (!palPtr) return 0; if (!palPtr) return 0;
@ -315,7 +315,7 @@ BOOL WINAPI ResizePalette(
int prevsize, size = sizeof(LOGPALETTE) + (cEntries - 1) * sizeof(PALETTEENTRY); int prevsize, size = sizeof(LOGPALETTE) + (cEntries - 1) * sizeof(PALETTEENTRY);
int* mapping = NULL; int* mapping = NULL;
TRACE(palette,"hpal = %04x, prev = %i, new = %i\n", TRACE("hpal = %04x, prev = %i, new = %i\n",
hPal, palPtr ? palPtr->logpalette.palNumEntries : -1, hPal, palPtr ? palPtr->logpalette.palNumEntries : -1,
cEntries ); cEntries );
if( !palPtr ) return FALSE; if( !palPtr ) return FALSE;
@ -375,7 +375,7 @@ BOOL WINAPI AnimatePalette(
UINT NumEntries, /* [in] Count of entries in palette */ UINT NumEntries, /* [in] Count of entries in palette */
const PALETTEENTRY* PaletteColors) /* [in] Pointer to first replacement */ const PALETTEENTRY* PaletteColors) /* [in] Pointer to first replacement */
{ {
TRACE(palette, "%04x (%i - %i)\n", hPal, StartIndex,StartIndex+NumEntries); TRACE("%04x (%i - %i)\n", hPal, StartIndex,StartIndex+NumEntries);
if( hPal != STOCK_DEFAULT_PALETTE ) if( hPal != STOCK_DEFAULT_PALETTE )
{ {
@ -419,7 +419,7 @@ UINT WINAPI SetSystemPaletteUse(
UINT use) /* [in] Palette-usage flag */ UINT use) /* [in] Palette-usage flag */
{ {
UINT old = SystemPaletteUse; UINT old = SystemPaletteUse;
FIXME(palette,"(%04x,%04x): stub\n", hdc, use ); FIXME("(%04x,%04x): stub\n", hdc, use );
SystemPaletteUse = use; SystemPaletteUse = use;
return old; return old;
} }
@ -473,7 +473,7 @@ UINT WINAPI GetSystemPaletteEntries(
UINT i; UINT i;
DC *dc; DC *dc;
TRACE(palette, "hdc=%04x,start=%i,count=%i\n", hdc,start,count); TRACE("hdc=%04x,start=%i,count=%i\n", hdc,start,count);
if (!(dc = (DC *) GDI_GetObjPtr( hdc, DC_MAGIC ))) return 0; if (!(dc = (DC *) GDI_GetObjPtr( hdc, DC_MAGIC ))) return 0;
if (!entries) return dc->w.devCaps->sizePalette; if (!entries) return dc->w.devCaps->sizePalette;
@ -488,7 +488,7 @@ UINT WINAPI GetSystemPaletteEntries(
{ {
*(COLORREF*)(entries + i) = COLOR_GetSystemPaletteEntry( start + i ); *(COLORREF*)(entries + i) = COLOR_GetSystemPaletteEntry( start + i );
TRACE(palette,"\tidx(%02x) -> RGB(%08lx)\n", TRACE("\tidx(%02x) -> RGB(%08lx)\n",
start + i, *(COLORREF*)(entries + i) ); start + i, *(COLORREF*)(entries + i) );
} }
GDI_HEAP_UNLOCK( hdc ); GDI_HEAP_UNLOCK( hdc );
@ -527,7 +527,7 @@ UINT WINAPI GetNearestPaletteIndex(
palObj->logpalette.palNumEntries, palObj->logpalette.palNumEntries,
NULL, color, FALSE ); NULL, color, FALSE );
TRACE(palette,"(%04x,%06lx): returning %d\n", hpalette, color, index ); TRACE("(%04x,%06lx): returning %d\n", hpalette, color, index );
GDI_HEAP_UNLOCK( hpalette ); GDI_HEAP_UNLOCK( hpalette );
return index; return index;
} }
@ -572,7 +572,7 @@ COLORREF WINAPI GetNearestColor(
GDI_HEAP_UNLOCK( dc->w.hPalette ); GDI_HEAP_UNLOCK( dc->w.hPalette );
} }
TRACE(palette,"(%06lx): returning %06lx\n", color, nearest ); TRACE("(%06lx): returning %06lx\n", color, nearest );
GDI_HEAP_UNLOCK( hdc ); GDI_HEAP_UNLOCK( hdc );
return nearest; return nearest;
} }
@ -623,7 +623,7 @@ HPALETTE16 WINAPI GDISelectPalette16( HDC16 hdc, HPALETTE16 hpal, WORD wBkg)
HPALETTE16 prev; HPALETTE16 prev;
DC *dc; DC *dc;
TRACE(palette, "%04x %04x\n", hdc, hpal ); TRACE("%04x %04x\n", hdc, hpal );
dc = (DC *) GDI_GetObjPtr( hdc, DC_MAGIC ); dc = (DC *) GDI_GetObjPtr( hdc, DC_MAGIC );
if (!dc) if (!dc)
@ -653,7 +653,7 @@ UINT16 WINAPI GDIRealizePalette16( HDC16 hdc )
if (!dc) return 0; if (!dc) return 0;
} }
TRACE(palette, "%04x...\n", hdc ); TRACE("%04x...\n", hdc );
if( dc && dc->w.hPalette != hLastRealizedPalette ) if( dc && dc->w.hPalette != hLastRealizedPalette )
{ {
@ -663,7 +663,7 @@ UINT16 WINAPI GDIRealizePalette16( HDC16 hdc )
palPtr = (PALETTEOBJ *) GDI_GetObjPtr( dc->w.hPalette, PALETTE_MAGIC ); palPtr = (PALETTEOBJ *) GDI_GetObjPtr( dc->w.hPalette, PALETTE_MAGIC );
if (!palPtr) { if (!palPtr) {
FIXME(palette,"invalid selected palette %04x\n",dc->w.hPalette); FIXME("invalid selected palette %04x\n",dc->w.hPalette);
return 0; return 0;
} }
@ -674,11 +674,11 @@ UINT16 WINAPI GDIRealizePalette16( HDC16 hdc )
GDI_HEAP_UNLOCK( dc->w.hPalette ); GDI_HEAP_UNLOCK( dc->w.hPalette );
hLastRealizedPalette = dc->w.hPalette; hLastRealizedPalette = dc->w.hPalette;
} }
else TRACE(palette, " skipping (hLastRealizedPalette = %04x)\n", else TRACE(" skipping (hLastRealizedPalette = %04x)\n",
hLastRealizedPalette); hLastRealizedPalette);
GDI_HEAP_UNLOCK( hdc ); GDI_HEAP_UNLOCK( hdc );
TRACE(palette, " realized %i colors.\n", realized ); TRACE(" realized %i colors.\n", realized );
return (UINT16)realized; return (UINT16)realized;
} }
@ -691,7 +691,7 @@ UINT16 WINAPI RealizeDefaultPalette16( HDC16 hdc )
DC *dc; DC *dc;
PALETTEOBJ* palPtr; PALETTEOBJ* palPtr;
TRACE(palette,"%04x\n", hdc ); TRACE("%04x\n", hdc );
dc = (DC *) GDI_GetObjPtr( hdc, DC_MAGIC ); dc = (DC *) GDI_GetObjPtr( hdc, DC_MAGIC );
if (!dc) if (!dc)
@ -757,10 +757,10 @@ HPALETTE WINAPI SelectPalette(
WORD wBkgPalette = 1; WORD wBkgPalette = 1;
PALETTEOBJ* lpt = (PALETTEOBJ*) GDI_GetObjPtr( hPal, PALETTE_MAGIC ); PALETTEOBJ* lpt = (PALETTEOBJ*) GDI_GetObjPtr( hPal, PALETTE_MAGIC );
TRACE(palette,"dc=%04x,pal=%04x,force=%i\n", hDC, hPal, bForceBackground); TRACE("dc=%04x,pal=%04x,force=%i\n", hDC, hPal, bForceBackground);
if( !lpt ) return 0; if( !lpt ) return 0;
TRACE(palette," entries = %d\n", lpt->logpalette.palNumEntries); TRACE(" entries = %d\n", lpt->logpalette.palNumEntries);
GDI_HEAP_UNLOCK( hPal ); GDI_HEAP_UNLOCK( hPal );
if( hPal != STOCK_DEFAULT_PALETTE ) if( hPal != STOCK_DEFAULT_PALETTE )
@ -865,6 +865,6 @@ BOOL WINAPI UpdateColors(
*/ */
VOID WINAPI SetMagicColors16(HDC16 hDC, COLORREF color, UINT16 index) VOID WINAPI SetMagicColors16(HDC16 hDC, COLORREF color, UINT16 index)
{ {
FIXME(palette,"(hDC %04x, color %04x, index %04x): stub\n", hDC, (int)color, index); FIXME("(hDC %04x, color %04x, index %04x): stub\n", hDC, (int)color, index);
} }

View File

@ -6,7 +6,7 @@
#include <string.h> #include <string.h>
#include "pen.h" #include "pen.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(gdi) DEFAULT_DEBUG_CHANNEL(gdi)
@ -19,7 +19,7 @@ HPEN16 WINAPI CreatePen16( INT16 style, INT16 width, COLORREF color )
{ {
LOGPEN logpen; LOGPEN logpen;
TRACE(gdi, "%d %d %06lx\n", style, width, color ); TRACE("%d %d %06lx\n", style, width, color );
logpen.lopnStyle = style; logpen.lopnStyle = style;
logpen.lopnWidth.x = width; logpen.lopnWidth.x = width;
@ -37,7 +37,7 @@ HPEN WINAPI CreatePen( INT style, INT width, COLORREF color )
{ {
LOGPEN logpen; LOGPEN logpen;
TRACE(gdi, "%d %d %06lx\n", style, width, color ); TRACE("%d %d %06lx\n", style, width, color );
logpen.lopnStyle = style; logpen.lopnStyle = style;
logpen.lopnWidth.x = width; logpen.lopnWidth.x = width;
@ -100,10 +100,10 @@ HPEN WINAPI ExtCreatePen( DWORD style, DWORD width,
LOGPEN logpen; LOGPEN logpen;
if ((style & PS_STYLE_MASK) == PS_USERSTYLE) if ((style & PS_STYLE_MASK) == PS_USERSTYLE)
FIXME(gdi, "PS_USERSTYLE not handled\n"); FIXME("PS_USERSTYLE not handled\n");
if ((style & PS_TYPE_MASK) == PS_GEOMETRIC) if ((style & PS_TYPE_MASK) == PS_GEOMETRIC)
if (brush->lbHatch) if (brush->lbHatch)
FIXME(gdi, "Hatches not implemented\n"); FIXME("Hatches not implemented\n");
logpen.lopnStyle = style & ~PS_TYPE_MASK; logpen.lopnStyle = style & ~PS_TYPE_MASK;
logpen.lopnWidth.x = (style & PS_GEOMETRIC) ? width : 1; logpen.lopnWidth.x = (style & PS_GEOMETRIC) ? width : 1;

View File

@ -85,7 +85,7 @@ SOFTWARE.
#include <string.h> #include <string.h>
#include "region.h" #include "region.h"
#include "winuser.h" #include "winuser.h"
#include "debug.h" #include "debugtools.h"
#include "heap.h" #include "heap.h"
#include "dc.h" #include "dc.h"
@ -112,11 +112,11 @@ static void REGION_DumpRegion(WINEREGION *pReg)
{ {
RECT *pRect, *pRectEnd = pReg->rects + pReg->numRects; RECT *pRect, *pRectEnd = pReg->rects + pReg->numRects;
TRACE(region, "Region %p: %d,%d - %d,%d %d rects\n", pReg, TRACE("Region %p: %d,%d - %d,%d %d rects\n", pReg,
pReg->extents.left, pReg->extents.top, pReg->extents.left, pReg->extents.top,
pReg->extents.right, pReg->extents.bottom, pReg->numRects); pReg->extents.right, pReg->extents.bottom, pReg->numRects);
for(pRect = pReg->rects; pRect < pRectEnd; pRect++) for(pRect = pReg->rects; pRect < pRectEnd; pRect++)
TRACE(region, "\t%d,%d - %d,%d\n", pRect->left, pRect->top, TRACE("\t%d,%d - %d,%d\n", pRect->left, pRect->top,
pRect->right, pRect->bottom); pRect->right, pRect->bottom);
return; return;
} }
@ -180,7 +180,7 @@ static void REGION_DestroyWineRegion( WINEREGION* pReg )
*/ */
BOOL REGION_DeleteObject( HRGN hrgn, RGNOBJ * obj ) BOOL REGION_DeleteObject( HRGN hrgn, RGNOBJ * obj )
{ {
TRACE(region, " %04x\n", hrgn ); TRACE(" %04x\n", hrgn );
REGION_DestroyWineRegion( obj->rgn ); REGION_DestroyWineRegion( obj->rgn );
return GDI_FreeObject( hrgn ); return GDI_FreeObject( hrgn );
@ -207,7 +207,7 @@ INT WINAPI OffsetRgn( HRGN hrgn, INT x, INT y )
int nbox = obj->rgn->numRects; int nbox = obj->rgn->numRects;
RECT *pbox = obj->rgn->rects; RECT *pbox = obj->rgn->rects;
TRACE(region, " %04x %d,%d\n", hrgn, x, y ); TRACE(" %04x %d,%d\n", hrgn, x, y );
if(nbox) { if(nbox) {
while(nbox--) { while(nbox--) {
pbox->left += x; pbox->left += x;
@ -249,7 +249,7 @@ INT WINAPI GetRgnBox( HRGN hrgn, LPRECT rect )
if (obj) if (obj)
{ {
INT ret; INT ret;
TRACE(region, " %04x\n", hrgn ); TRACE(" %04x\n", hrgn );
rect->left = obj->rgn->extents.left; rect->left = obj->rgn->extents.left;
rect->top = obj->rgn->extents.top; rect->top = obj->rgn->extents.top;
rect->right = obj->rgn->extents.right; rect->right = obj->rgn->extents.right;
@ -273,7 +273,7 @@ HRGN16 WINAPI CreateRectRgn16(INT16 left, INT16 top, INT16 right, INT16 bottom)
if (!(hrgn = (HRGN16)REGION_CreateRegion(RGN_DEFAULT_RECTS))) if (!(hrgn = (HRGN16)REGION_CreateRegion(RGN_DEFAULT_RECTS)))
return 0; return 0;
TRACE(region, "\n"); TRACE("\n");
SetRectRgn16(hrgn, left, top, right, bottom); SetRectRgn16(hrgn, left, top, right, bottom);
return hrgn; return hrgn;
} }
@ -290,7 +290,7 @@ HRGN WINAPI CreateRectRgn(INT left, INT top, INT right, INT bottom)
if (!(hrgn = REGION_CreateRegion(RGN_DEFAULT_RECTS))) if (!(hrgn = REGION_CreateRegion(RGN_DEFAULT_RECTS)))
return 0; return 0;
TRACE(region, "\n"); TRACE("\n");
SetRectRgn(hrgn, left, top, right, bottom); SetRectRgn(hrgn, left, top, right, bottom);
return hrgn; return hrgn;
} }
@ -338,7 +338,7 @@ BOOL WINAPI SetRectRgn( HRGN hrgn, INT left, INT top,
{ {
RGNOBJ * obj; RGNOBJ * obj;
TRACE(region, " %04x %d,%d-%d,%d\n", TRACE(" %04x %d,%d-%d,%d\n",
hrgn, left, top, right, bottom ); hrgn, left, top, right, bottom );
if (!(obj = (RGNOBJ *) GDI_GetObjPtr( hrgn, REGION_MAGIC ))) return FALSE; if (!(obj = (RGNOBJ *) GDI_GetObjPtr( hrgn, REGION_MAGIC ))) return FALSE;
@ -412,7 +412,7 @@ HRGN WINAPI CreateRoundRectRgn( INT left, INT top,
d = (ellipse_height < 128) ? ((3 * ellipse_height) >> 2) : 64; d = (ellipse_height < 128) ? ((3 * ellipse_height) >> 2) : 64;
if (!(hrgn = REGION_CreateRegion(d))) return 0; if (!(hrgn = REGION_CreateRegion(d))) return 0;
obj = (RGNOBJ *) GDI_HEAP_LOCK( hrgn ); obj = (RGNOBJ *) GDI_HEAP_LOCK( hrgn );
TRACE(region,"(%d,%d-%d,%d %dx%d): ret=%04x\n", TRACE("(%d,%d-%d,%d %dx%d): ret=%04x\n",
left, top, right, bottom, ellipse_width, ellipse_height, hrgn ); left, top, right, bottom, ellipse_width, ellipse_height, hrgn );
/* Check parameters */ /* Check parameters */
@ -543,7 +543,7 @@ DWORD WINAPI GetRegionData(HRGN hrgn, DWORD count, LPRGNDATA rgndata)
DWORD size; DWORD size;
RGNOBJ *obj = (RGNOBJ *) GDI_GetObjPtr( hrgn, REGION_MAGIC ); RGNOBJ *obj = (RGNOBJ *) GDI_GetObjPtr( hrgn, REGION_MAGIC );
TRACE(region, " %04x count = %ld, rgndata = %p\n", TRACE(" %04x count = %ld, rgndata = %p\n",
hrgn, count, rgndata); hrgn, count, rgndata);
if(!obj) return 0; if(!obj) return 0;
@ -587,17 +587,17 @@ HRGN WINAPI ExtCreateRegion( const XFORM* lpXform, DWORD dwCount, const RGNDATA*
{ {
HRGN hrgn; HRGN hrgn;
TRACE(region, " %p %ld %p = ", lpXform, dwCount, rgndata ); TRACE(" %p %ld %p = ", lpXform, dwCount, rgndata );
if( lpXform ) if( lpXform )
WARN(region, "(Xform not implemented - ignored) "); WARN("(Xform not implemented - ignored) ");
if( rgndata->rdh.iType != RDH_RECTANGLES ) if( rgndata->rdh.iType != RDH_RECTANGLES )
{ {
/* FIXME: We can use CreatePolyPolygonRgn() here /* FIXME: We can use CreatePolyPolygonRgn() here
* for trapezoidal data */ * for trapezoidal data */
WARN(region, "(Unsupported region data) "); WARN("(Unsupported region data) ");
goto fail; goto fail;
} }
@ -611,11 +611,11 @@ HRGN WINAPI ExtCreateRegion( const XFORM* lpXform, DWORD dwCount, const RGNDATA*
REGION_UnionRectWithRegion( pCurRect, obj->rgn ); REGION_UnionRectWithRegion( pCurRect, obj->rgn );
GDI_HEAP_UNLOCK( hrgn ); GDI_HEAP_UNLOCK( hrgn );
TRACE(region,"%04x\n", hrgn ); TRACE("%04x\n", hrgn );
return hrgn; return hrgn;
} }
fail: fail:
WARN(region, "Failed\n"); WARN("Failed\n");
return 0; return 0;
} }
@ -832,7 +832,7 @@ BOOL REGION_LPTODP( HDC hdc, HRGN hDest, HRGN hSrc )
DC * dc = DC_GetDCPtr( hdc ); DC * dc = DC_GetDCPtr( hdc );
RECT tmpRect; RECT tmpRect;
TRACE(region, " hdc=%04x dest=%04x src=%04x\n", TRACE(" hdc=%04x dest=%04x src=%04x\n",
hdc, hDest, hSrc) ; hdc, hDest, hSrc) ;
if (dc->w.MapMode == MM_TEXT) /* Requires only a translation */ if (dc->w.MapMode == MM_TEXT) /* Requires only a translation */
@ -887,7 +887,7 @@ INT WINAPI CombineRgn(HRGN hDest, HRGN hSrc1, HRGN hSrc2, INT mode)
RGNOBJ *destObj = (RGNOBJ *) GDI_GetObjPtr( hDest, REGION_MAGIC); RGNOBJ *destObj = (RGNOBJ *) GDI_GetObjPtr( hDest, REGION_MAGIC);
INT result = ERROR; INT result = ERROR;
TRACE(region, " %04x,%04x -> %04x mode=%x\n", TRACE(" %04x,%04x -> %04x mode=%x\n",
hSrc1, hSrc2, hDest, mode ); hSrc1, hSrc2, hDest, mode );
if (destObj) if (destObj)
{ {
@ -895,7 +895,7 @@ INT WINAPI CombineRgn(HRGN hDest, HRGN hSrc1, HRGN hSrc2, INT mode)
if (src1Obj) if (src1Obj)
{ {
TRACE(region, "dump:\n"); TRACE("dump:\n");
if(TRACE_ON(region)) if(TRACE_ON(region))
REGION_DumpRegion(src1Obj->rgn); REGION_DumpRegion(src1Obj->rgn);
if (mode == RGN_COPY) if (mode == RGN_COPY)
@ -909,7 +909,7 @@ INT WINAPI CombineRgn(HRGN hDest, HRGN hSrc1, HRGN hSrc2, INT mode)
if (src2Obj) if (src2Obj)
{ {
TRACE(region, "dump:\n"); TRACE("dump:\n");
if(TRACE_ON(region)) if(TRACE_ON(region))
REGION_DumpRegion(src2Obj->rgn); REGION_DumpRegion(src2Obj->rgn);
switch (mode) switch (mode)
@ -933,7 +933,7 @@ INT WINAPI CombineRgn(HRGN hDest, HRGN hSrc1, HRGN hSrc2, INT mode)
} }
GDI_HEAP_UNLOCK( hSrc1 ); GDI_HEAP_UNLOCK( hSrc1 );
} }
TRACE(region, "dump:\n"); TRACE("dump:\n");
if(TRACE_ON(region)) if(TRACE_ON(region))
REGION_DumpRegion(destObj->rgn); REGION_DumpRegion(destObj->rgn);
@ -1988,7 +1988,7 @@ static void REGION_InsertEdgeInET(EdgeTable *ET, EdgeTableEntry *ETE,
tmpSLLBlock = HeapAlloc( SystemHeap, 0, sizeof(ScanLineListBlock)); tmpSLLBlock = HeapAlloc( SystemHeap, 0, sizeof(ScanLineListBlock));
if(!tmpSLLBlock) if(!tmpSLLBlock)
{ {
WARN(region, "Can't alloc SLLB\n"); WARN("Can't alloc SLLB\n");
return; return;
} }
(*SLLBlock)->next = tmpSLLBlock; (*SLLBlock)->next = tmpSLLBlock;
@ -2436,7 +2436,7 @@ HRGN WINAPI CreatePolyPolygonRgn(const POINT *Pts, const INT *Count,
if (iPts == NUMPTSTOBUFFER) { if (iPts == NUMPTSTOBUFFER) {
tmpPtBlock = HeapAlloc( SystemHeap, 0, sizeof(POINTBLOCK)); tmpPtBlock = HeapAlloc( SystemHeap, 0, sizeof(POINTBLOCK));
if(!tmpPtBlock) { if(!tmpPtBlock) {
WARN(region, "Can't alloc tPB\n"); WARN("Can't alloc tPB\n");
return 0; return 0;
} }
curPtBlock->next = tmpPtBlock; curPtBlock->next = tmpPtBlock;
@ -2487,7 +2487,7 @@ HRGN WINAPI CreatePolyPolygonRgn(const POINT *Pts, const INT *Count,
tmpPtBlock = HeapAlloc( SystemHeap, 0, tmpPtBlock = HeapAlloc( SystemHeap, 0,
sizeof(POINTBLOCK) ); sizeof(POINTBLOCK) );
if(!tmpPtBlock) { if(!tmpPtBlock) {
WARN(region, "Can't alloc tPB\n"); WARN("Can't alloc tPB\n");
return 0; return 0;
} }
curPtBlock->next = tmpPtBlock; curPtBlock->next = tmpPtBlock;
@ -2577,7 +2577,7 @@ HRGN WINAPI CreatePolygonRgn( const POINT *points, INT count,
*/ */
HRGN WINAPI GetRandomRgn(DWORD dwArg1, DWORD dwArg2, DWORD dwArg3) HRGN WINAPI GetRandomRgn(DWORD dwArg1, DWORD dwArg2, DWORD dwArg3)
{ {
FIXME (region, "(0x%08lx 0x%08lx 0x%08lx): empty stub!\n", FIXME("(0x%08lx 0x%08lx 0x%08lx): empty stub!\n",
dwArg1, dwArg2, dwArg3); dwArg1, dwArg2, dwArg3);
return 0; return 0;
@ -2637,7 +2637,7 @@ empty:
return FALSE; return FALSE;
} }
TRACE(region,"cropped to empty!\n"); TRACE("cropped to empty!\n");
EMPTY_REGION(rgnDst); EMPTY_REGION(rgnDst);
} }
else /* region box and clipping rect appear to intersect */ else /* region box and clipping rect appear to intersect */
@ -2669,7 +2669,7 @@ empty:
if( TRACE_ON(region) ) if( TRACE_ON(region) )
{ {
REGION_DumpRegion( rgnSrc ); REGION_DumpRegion( rgnSrc );
TRACE(region,"\tclipa = %i, clipb = %i\n", clipa, clipb ); TRACE("\tclipa = %i, clipb = %i\n", clipa, clipb );
} }
for( i = clipa, j = 0; i < clipb ; i++ ) for( i = clipa, j = 0; i < clipb ; i++ )
@ -2719,7 +2719,7 @@ empty:
if( TRACE_ON(region) ) if( TRACE_ON(region) )
{ {
TRACE(region,"result:\n"); TRACE("result:\n");
REGION_DumpRegion( rgnDst ); REGION_DumpRegion( rgnDst );
} }
} }
@ -2793,10 +2793,10 @@ HRGN REGION_CropRgn( HRGN hDst, HRGN hSrc, const RECT *lpRect, const POINT *lpPt
if( !lpPt ) lpPt = &pt; if( !lpPt ) lpPt = &pt;
if( lpRect ) if( lpRect )
TRACE(region, "src %p -> dst %p (%i,%i)-(%i,%i) by (%li,%li)\n", objSrc->rgn, rgnDst, TRACE("src %p -> dst %p (%i,%i)-(%i,%i) by (%li,%li)\n", objSrc->rgn, rgnDst,
lpRect->left, lpRect->top, lpRect->right, lpRect->bottom, lpPt->x, lpPt->y ); lpRect->left, lpRect->top, lpRect->right, lpRect->bottom, lpPt->x, lpPt->y );
else else
TRACE(region, "src %p -> dst %p by (%li,%li)\n", objSrc->rgn, rgnDst, lpPt->x, lpPt->y ); TRACE("src %p -> dst %p by (%li,%li)\n", objSrc->rgn, rgnDst, lpPt->x, lpPt->y );
if( REGION_CropAndOffsetRegion( lpPt, lpRect, objSrc->rgn, rgnDst ) == FALSE ) if( REGION_CropAndOffsetRegion( lpPt, lpRect, objSrc->rgn, rgnDst ) == FALSE )
{ {

View File

@ -11,7 +11,7 @@
#include "dc.h" #include "dc.h"
#include "gdi.h" #include "gdi.h"
#include "heap.h" #include "heap.h"
#include "debug.h" #include "debugtools.h"
#include "cache.h" #include "cache.h"
#include "debugstr.h" #include "debugstr.h"
@ -202,7 +202,7 @@ INT16 WINAPI DrawText16( HDC16 hdc, LPCSTR str, INT16 i_count,
int width = rect->right - rect->left; int width = rect->right - rect->left;
int max_width = 0; int max_width = 0;
TRACE(text,"%s, %d , [(%d,%d),(%d,%d)]\n", TRACE("%s, %d , [(%d,%d),(%d,%d)]\n",
debugstr_an (str, count), count, debugstr_an (str, count), count,
rect->left, rect->top, rect->right, rect->bottom); rect->left, rect->top, rect->right, rect->bottom);
@ -325,9 +325,9 @@ INT WINAPI DrawTextW( HDC hdc, LPCWSTR str, INT count,
INT WINAPI DrawTextExA( HDC hdc, LPCSTR str, INT count, INT WINAPI DrawTextExA( HDC hdc, LPCSTR str, INT count,
LPRECT rect, UINT flags, LPDRAWTEXTPARAMS dtp ) LPRECT rect, UINT flags, LPDRAWTEXTPARAMS dtp )
{ {
TRACE(text,"(%d,'%s',%d,%p,0x%08x,%p)\n",hdc,str,count,rect,flags,dtp); TRACE("(%d,'%s',%d,%p,0x%08x,%p)\n",hdc,str,count,rect,flags,dtp);
if(dtp) { if(dtp) {
FIXME(text,"Ignores params:%d,%d,%d,%d,%d\n",dtp->cbSize, FIXME("Ignores params:%d,%d,%d,%d,%d\n",dtp->cbSize,
dtp->iTabLength,dtp->iLeftMargin,dtp->iRightMargin, dtp->iTabLength,dtp->iLeftMargin,dtp->iRightMargin,
dtp->uiLengthDrawn); dtp->uiLengthDrawn);
} }
@ -340,8 +340,8 @@ INT WINAPI DrawTextExA( HDC hdc, LPCSTR str, INT count,
INT WINAPI DrawTextExW( HDC hdc, LPCWSTR str, INT count, INT WINAPI DrawTextExW( HDC hdc, LPCWSTR str, INT count,
LPRECT rect, UINT flags, LPDRAWTEXTPARAMS dtp ) LPRECT rect, UINT flags, LPDRAWTEXTPARAMS dtp )
{ {
TRACE(text,"(%d,%p,%d,%p,0x%08x,%p)\n",hdc,str,count,rect,flags,dtp); TRACE("(%d,%p,%d,%p,0x%08x,%p)\n",hdc,str,count,rect,flags,dtp);
FIXME(text,"ignores extended functionality\n"); FIXME("ignores extended functionality\n");
return DrawTextW(hdc,str,count,rect,flags); return DrawTextW(hdc,str,count,rect,flags);
} }
@ -641,7 +641,7 @@ LONG WINAPI TabbedTextOut16( HDC16 hdc, INT16 x, INT16 y, LPCSTR lpstr,
INT16 count, INT16 cTabStops, INT16 count, INT16 cTabStops,
const INT16 *lpTabPos, INT16 nTabOrg ) const INT16 *lpTabPos, INT16 nTabOrg )
{ {
TRACE(text, "%04x %d,%d '%.*s' %d\n", TRACE("%04x %d,%d '%.*s' %d\n",
hdc, x, y, count, lpstr, count ); hdc, x, y, count, lpstr, count );
return TEXT_TabbedTextOut( hdc, x, y, lpstr, count, cTabStops, return TEXT_TabbedTextOut( hdc, x, y, lpstr, count, cTabStops,
lpTabPos, NULL, nTabOrg, TRUE ); lpTabPos, NULL, nTabOrg, TRUE );
@ -655,7 +655,7 @@ LONG WINAPI TabbedTextOutA( HDC hdc, INT x, INT y, LPCSTR lpstr,
INT count, INT cTabStops, INT count, INT cTabStops,
const INT *lpTabPos, INT nTabOrg ) const INT *lpTabPos, INT nTabOrg )
{ {
TRACE(text, "%04x %d,%d '%.*s' %d\n", TRACE("%04x %d,%d '%.*s' %d\n",
hdc, x, y, count, lpstr, count ); hdc, x, y, count, lpstr, count );
return TEXT_TabbedTextOut( hdc, x, y, lpstr, count, cTabStops, return TEXT_TabbedTextOut( hdc, x, y, lpstr, count, cTabStops,
NULL, lpTabPos, nTabOrg, TRUE ); NULL, lpTabPos, nTabOrg, TRUE );
@ -685,7 +685,7 @@ LONG WINAPI TabbedTextOutW( HDC hdc, INT x, INT y, LPCWSTR str,
DWORD WINAPI GetTabbedTextExtent16( HDC16 hdc, LPCSTR lpstr, INT16 count, DWORD WINAPI GetTabbedTextExtent16( HDC16 hdc, LPCSTR lpstr, INT16 count,
INT16 cTabStops, const INT16 *lpTabPos ) INT16 cTabStops, const INT16 *lpTabPos )
{ {
TRACE(text, "%04x '%.*s' %d\n", TRACE("%04x '%.*s' %d\n",
hdc, count, lpstr, count ); hdc, count, lpstr, count );
return TEXT_TabbedTextOut( hdc, 0, 0, lpstr, count, cTabStops, return TEXT_TabbedTextOut( hdc, 0, 0, lpstr, count, cTabStops,
lpTabPos, NULL, 0, FALSE ); lpTabPos, NULL, 0, FALSE );
@ -698,7 +698,7 @@ DWORD WINAPI GetTabbedTextExtent16( HDC16 hdc, LPCSTR lpstr, INT16 count,
DWORD WINAPI GetTabbedTextExtentA( HDC hdc, LPCSTR lpstr, INT count, DWORD WINAPI GetTabbedTextExtentA( HDC hdc, LPCSTR lpstr, INT count,
INT cTabStops, const INT *lpTabPos ) INT cTabStops, const INT *lpTabPos )
{ {
TRACE(text, "%04x '%.*s' %d\n", TRACE("%04x '%.*s' %d\n",
hdc, count, lpstr, count ); hdc, count, lpstr, count );
return TEXT_TabbedTextOut( hdc, 0, 0, lpstr, count, cTabStops, return TEXT_TabbedTextOut( hdc, 0, 0, lpstr, count, cTabStops,
NULL, lpTabPos, 0, FALSE ); NULL, lpTabPos, 0, FALSE );

View File

@ -9,7 +9,7 @@
#include "winbase.h" #include "winbase.h"
#include "server.h" #include "server.h"
#include "winerror.h" #include "winerror.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(win32) DEFAULT_DEBUG_CHANNEL(win32)
@ -105,7 +105,7 @@ HANDLE WINAPI ConvertToGlobalHandle(HANDLE hSrc)
* SetHandleContext (KERNEL32) * SetHandleContext (KERNEL32)
*/ */
BOOL WINAPI SetHandleContext(HANDLE hnd,DWORD context) { BOOL WINAPI SetHandleContext(HANDLE hnd,DWORD context) {
FIXME(win32,"(%d,%ld), stub. The external WSOCK32 will not work with WINE, do not use it.\n",hnd,context); FIXME("(%d,%ld), stub. The external WSOCK32 will not work with WINE, do not use it.\n",hnd,context);
SetLastError(ERROR_CALL_NOT_IMPLEMENTED); SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
return FALSE; return FALSE;
} }
@ -114,7 +114,7 @@ BOOL WINAPI SetHandleContext(HANDLE hnd,DWORD context) {
* GetHandleContext (KERNEL32) * GetHandleContext (KERNEL32)
*/ */
DWORD WINAPI GetHandleContext(HANDLE hnd) { DWORD WINAPI GetHandleContext(HANDLE hnd) {
FIXME(win32,"(%d), stub. The external WSOCK32 will not work with WINE, do not use it.\n",hnd); FIXME("(%d), stub. The external WSOCK32 will not work with WINE, do not use it.\n",hnd);
SetLastError(ERROR_CALL_NOT_IMPLEMENTED); SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
return 0; return 0;
} }
@ -123,7 +123,7 @@ DWORD WINAPI GetHandleContext(HANDLE hnd) {
* CreateSocketHandle (KERNEL32) * CreateSocketHandle (KERNEL32)
*/ */
HANDLE WINAPI CreateSocketHandle(void) { HANDLE WINAPI CreateSocketHandle(void) {
FIXME(win32,"(), stub. The external WSOCK32 will not work with WINE, do not use it.\n"); FIXME("(), stub. The external WSOCK32 will not work with WINE, do not use it.\n");
SetLastError(ERROR_CALL_NOT_IMPLEMENTED); SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
return INVALID_HANDLE_VALUE; return INVALID_HANDLE_VALUE;
} }

View File

@ -8,7 +8,7 @@
#include <unistd.h> #include <unistd.h>
#include "services.h" #include "services.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(timer) DEFAULT_DEBUG_CHANNEL(timer)
@ -159,13 +159,13 @@ static DWORD CALLBACK SERVICE_Loop( SERVICETABLE *service )
/* Wait until some condition satisfied */ /* Wait until some condition satisfied */
TRACE( timer, "Waiting for %d objects with timeout %ld\n", TRACE("Waiting for %d objects with timeout %ld\n",
count, timeout ); count, timeout );
retval = WaitForMultipleObjectsEx( count, handles, retval = WaitForMultipleObjectsEx( count, handles,
FALSE, timeout, TRUE ); FALSE, timeout, TRUE );
TRACE( timer, "Wait returned: %ld\n", retval ); TRACE("Wait returned: %ld\n", retval );
} }
return 0L; return 0L;

View File

@ -16,7 +16,6 @@
#include "message.h" #include "message.h"
#include "x11drv.h" #include "x11drv.h"
#include "server.h" #include "server.h"
#include "debug.h"
/*********************************************************************** /***********************************************************************

View File

@ -28,7 +28,7 @@ static int *ph_errno = &h_errno;
#include "thread.h" #include "thread.h"
#include "server.h" #include "server.h"
#include "winbase.h" #include "winbase.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(thread) DEFAULT_DEBUG_CHANNEL(thread)
@ -166,7 +166,7 @@ int SYSDEPS_SpawnThread( THDB *thread )
#endif /* NO_REENTRANT_LIBC */ #endif /* NO_REENTRANT_LIBC */
FIXME(thread, "CreateThread: stub\n" ); FIXME("CreateThread: stub\n" );
return 0; return 0;
} }

View File

@ -10,7 +10,7 @@
#include "syslevel.h" #include "syslevel.h"
#include "heap.h" #include "heap.h"
#include "stackframe.h" #include "stackframe.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(win32) DEFAULT_DEBUG_CHANNEL(win32)
@ -62,7 +62,7 @@ VOID WINAPI _CreateSysLevel(SYSLEVEL *lock, INT level)
MakeCriticalSectionGlobal( &lock->crst ); MakeCriticalSectionGlobal( &lock->crst );
lock->level = level; lock->level = level;
TRACE( win32, "(%p, %d): handle is %d\n", TRACE("(%p, %d): handle is %d\n",
lock, level, lock->crst.LockSemaphore ); lock, level, lock->crst.LockSemaphore );
} }
@ -74,14 +74,14 @@ VOID WINAPI _EnterSysLevel(SYSLEVEL *lock)
THDB *thdb = THREAD_Current(); THDB *thdb = THREAD_Current();
int i; int i;
TRACE( win32, "(%p, level %d): thread %p (fs %04x, pid %d) count before %ld\n", TRACE("(%p, level %d): thread %p (fs %04x, pid %d) count before %ld\n",
lock, lock->level, thdb->server_tid, thdb->teb_sel, getpid(), lock, lock->level, thdb->server_tid, thdb->teb_sel, getpid(),
thdb->sys_count[lock->level] ); thdb->sys_count[lock->level] );
for ( i = 3; i > lock->level; i-- ) for ( i = 3; i > lock->level; i-- )
if ( thdb->sys_count[i] > 0 ) if ( thdb->sys_count[i] > 0 )
{ {
ERR( win32, "(%p, level %d): Holding %p, level %d. Expect deadlock!\n", ERR("(%p, level %d): Holding %p, level %d. Expect deadlock!\n",
lock, lock->level, thdb->sys_mutex[i], i ); lock, lock->level, thdb->sys_mutex[i], i );
} }
@ -90,7 +90,7 @@ VOID WINAPI _EnterSysLevel(SYSLEVEL *lock)
thdb->sys_count[lock->level]++; thdb->sys_count[lock->level]++;
thdb->sys_mutex[lock->level] = lock; thdb->sys_mutex[lock->level] = lock;
TRACE( win32, "(%p, level %d): thread %p (fs %04x, pid %d) count after %ld\n", TRACE("(%p, level %d): thread %p (fs %04x, pid %d) count after %ld\n",
lock, lock->level, thdb->server_tid, thdb->teb_sel, getpid(), lock, lock->level, thdb->server_tid, thdb->teb_sel, getpid(),
thdb->sys_count[lock->level] ); thdb->sys_count[lock->level] );
@ -105,13 +105,13 @@ VOID WINAPI _LeaveSysLevel(SYSLEVEL *lock)
{ {
THDB *thdb = THREAD_Current(); THDB *thdb = THREAD_Current();
TRACE( win32, "(%p, level %d): thread %p (fs %04x, pid %d) count before %ld\n", TRACE("(%p, level %d): thread %p (fs %04x, pid %d) count before %ld\n",
lock, lock->level, thdb->server_tid, thdb->teb_sel, getpid(), lock, lock->level, thdb->server_tid, thdb->teb_sel, getpid(),
thdb->sys_count[lock->level] ); thdb->sys_count[lock->level] );
if ( thdb->sys_count[lock->level] <= 0 || thdb->sys_mutex[lock->level] != lock ) if ( thdb->sys_count[lock->level] <= 0 || thdb->sys_mutex[lock->level] != lock )
{ {
ERR( win32, "(%p, level %d): Invalid state: count %ld mutex %p.\n", ERR("(%p, level %d): Invalid state: count %ld mutex %p.\n",
lock, lock->level, thdb->sys_count[lock->level], lock, lock->level, thdb->sys_count[lock->level],
thdb->sys_mutex[lock->level] ); thdb->sys_mutex[lock->level] );
} }
@ -123,7 +123,7 @@ VOID WINAPI _LeaveSysLevel(SYSLEVEL *lock)
LeaveCriticalSection( &lock->crst ); LeaveCriticalSection( &lock->crst );
TRACE( win32, "(%p, level %d): thread %p (fs %04x, pid %d) count after %ld\n", TRACE("(%p, level %d): thread %p (fs %04x, pid %d) count after %ld\n",
lock, lock->level, thdb->server_tid, thdb->teb_sel, getpid(), lock, lock->level, thdb->server_tid, thdb->teb_sel, getpid(),
thdb->sys_count[lock->level] ); thdb->sys_count[lock->level] );
} }
@ -152,7 +152,7 @@ DWORD WINAPI _ConfirmSysLevel(SYSLEVEL *lock)
*/ */
VOID WINAPI _CheckNotSysLevel(SYSLEVEL *lock) VOID WINAPI _CheckNotSysLevel(SYSLEVEL *lock)
{ {
FIXME(win32, "(%p)\n", lock); FIXME("(%p)\n", lock);
} }
@ -210,7 +210,7 @@ VOID SYSLEVEL_ReleaseWin16Lock(VOID)
ReleaseThunkLock(&count); ReleaseThunkLock(&count);
if (count > 0xffff) if (count > 0xffff)
ERR(win32, "Win16Mutex recursion count too large!\n"); ERR("Win16Mutex recursion count too large!\n");
CURRENT_STACK16->mutex_count = (WORD)count; CURRENT_STACK16->mutex_count = (WORD)count;
} }
@ -223,7 +223,7 @@ VOID SYSLEVEL_RestoreWin16Lock(VOID)
DWORD count = CURRENT_STACK16->mutex_count; DWORD count = CURRENT_STACK16->mutex_count;
if (!count) if (!count)
ERR(win32, "Win16Mutex recursion count is zero!\n"); ERR("Win16Mutex recursion count is zero!\n");
RestoreThunkLock(count); RestoreThunkLock(count);
} }
@ -239,7 +239,7 @@ VOID SYSLEVEL_CheckNotLevel( INT level )
for ( i = 3; i >= level; i-- ) for ( i = 3; i >= level; i-- )
if ( thdb->sys_count[i] > 0 ) if ( thdb->sys_count[i] > 0 )
{ {
ERR( win32, "(%d): Holding lock of level %d!\n", ERR("(%d): Holding lock of level %d!\n",
level, i ); level, i );
kill( getpid(), SIGHUP ); kill( getpid(), SIGHUP );

View File

@ -22,7 +22,7 @@
#include "server.h" #include "server.h"
#include "services.h" #include "services.h"
#include "stackframe.h" #include "stackframe.h"
#include "debug.h" #include "debugtools.h"
#include "queue.h" #include "queue.h"
#include "hook.h" #include "hook.h"
@ -109,7 +109,7 @@ static BOOL THREAD_InitTHDB( THDB *thdb, DWORD stack_size, BOOL alloc_stack16,
if (stack_size<1024*1024) if (stack_size<1024*1024)
stack_size = 1024 * 1024; stack_size = 1024 * 1024;
if (stack_size >= 16*1024*1024) if (stack_size >= 16*1024*1024)
WARN(thread,"Thread stack size is %ld MB.\n",stack_size/1024/1024); WARN("Thread stack size is %ld MB.\n",stack_size/1024/1024);
thdb->stack_base = VirtualAlloc(NULL, thdb->stack_base = VirtualAlloc(NULL,
stack_size + (alloc_stack16 ? 0x10000 : 0), stack_size + (alloc_stack16 ? 0x10000 : 0),
MEM_COMMIT, PAGE_EXECUTE_READWRITE ); MEM_COMMIT, PAGE_EXECUTE_READWRITE );
@ -158,7 +158,7 @@ void CALLBACK THREAD_FreeTHDB( ULONG_PTR arg )
THDB *thdb = (THDB *)arg; THDB *thdb = (THDB *)arg;
THDB **pptr = &THREAD_First; THDB **pptr = &THREAD_First;
TRACE( thread, "(%p) called\n", thdb ); TRACE("(%p) called\n", thdb );
SERVICE_Delete( thdb->cleanup ); SERVICE_Delete( thdb->cleanup );
PROCESS_CallUserSignalProc( USIG_THREAD_EXIT, 0, 0 ); PROCESS_CallUserSignalProc( USIG_THREAD_EXIT, 0, 0 );
@ -198,7 +198,7 @@ THDB *THREAD_CreateInitialThread( PDB *pdb, int server_fd )
if (!(initial_thdb.teb_sel = SELECTOR_AllocBlock( &initial_thdb.teb, 0x1000, if (!(initial_thdb.teb_sel = SELECTOR_AllocBlock( &initial_thdb.teb, 0x1000,
SEGMENT_DATA, TRUE, FALSE ))) SEGMENT_DATA, TRUE, FALSE )))
{ {
MSG("Could not allocate fs register for initial thread\n" ); MESSAGE("Could not allocate fs register for initial thread\n" );
return NULL; return NULL;
} }
SET_CUR_THREAD( &initial_thdb ); SET_CUR_THREAD( &initial_thdb );
@ -372,7 +372,7 @@ DWORD WINAPI GetLastError(void)
{ {
THDB *thread = THREAD_Current(); THDB *thread = THREAD_Current();
DWORD ret = thread->last_error; DWORD ret = thread->last_error;
TRACE(thread,"0x%lx\n",ret); TRACE("0x%lx\n",ret);
return ret; return ret;
} }
@ -389,7 +389,7 @@ void WINAPI SetLastError(
THDB *thread = THREAD_Current(); THDB *thread = THREAD_Current();
/* This one must work before we have a thread (FIXME) */ /* This one must work before we have a thread (FIXME) */
TRACE(thread,"%p error=0x%lx\n",thread,error); TRACE("%p error=0x%lx\n",thread,error);
if (thread) if (thread)
thread->last_error = error; thread->last_error = error;
@ -406,7 +406,7 @@ void WINAPI SetLastErrorEx(
DWORD error, /* [in] Per-thread error code */ DWORD error, /* [in] Per-thread error code */
DWORD type) /* [in] Error type */ DWORD type) /* [in] Error type */
{ {
TRACE(thread, "(0x%08lx, 0x%08lx)\n", error,type); TRACE("(0x%08lx, 0x%08lx)\n", error,type);
switch(type) { switch(type) {
case 0: case 0:
break; break;
@ -415,7 +415,7 @@ void WINAPI SetLastErrorEx(
case SLE_WARNING: case SLE_WARNING:
/* Fall through for now */ /* Fall through for now */
default: default:
FIXME(thread, "(error=%08lx, type=%08lx): Unhandled type\n", error,type); FIXME("(error=%08lx, type=%08lx): Unhandled type\n", error,type);
break; break;
} }
SetLastError( error ); SetLastError( error );
@ -546,7 +546,7 @@ BOOL WINAPI SetThreadContext(
HANDLE handle, /* [in] Handle to thread with context */ HANDLE handle, /* [in] Handle to thread with context */
CONTEXT *context) /* [out] Address of context structure */ CONTEXT *context) /* [out] Address of context structure */
{ {
FIXME( thread, "not implemented\n" ); FIXME("not implemented\n" );
return TRUE; return TRUE;
} }
@ -563,7 +563,7 @@ BOOL WINAPI GetThreadContext(
{ {
WORD cs, ds; WORD cs, ds;
FIXME( thread, "returning dummy info\n" ); FIXME("returning dummy info\n" );
/* make up some plausible values for segment registers */ /* make up some plausible values for segment registers */
GET_CS(cs); GET_CS(cs);
@ -746,7 +746,7 @@ BOOL WINAPI GetThreadTimes(
LPFILETIME kerneltime, /* [out] Time thread spent in kernel mode */ LPFILETIME kerneltime, /* [out] Time thread spent in kernel mode */
LPFILETIME usertime) /* [out] Time thread spent in user mode */ LPFILETIME usertime) /* [out] Time thread spent in user mode */
{ {
FIXME(thread,"(0x%08x): stub\n",thread); FIXME("(0x%08x): stub\n",thread);
SetLastError(ERROR_CALL_NOT_IMPLEMENTED); SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
return FALSE; return FALSE;
} }
@ -841,7 +841,7 @@ CLEANUP:
*/ */
VOID WINAPI VWin32_BoostThreadGroup( DWORD threadId, INT boost ) VOID WINAPI VWin32_BoostThreadGroup( DWORD threadId, INT boost )
{ {
FIXME(thread, "(0x%08lx,%d): stub\n", threadId, boost); FIXME("(0x%08lx,%d): stub\n", threadId, boost);
} }
/********************************************************************** /**********************************************************************
@ -849,7 +849,7 @@ VOID WINAPI VWin32_BoostThreadGroup( DWORD threadId, INT boost )
*/ */
VOID WINAPI VWin32_BoostThreadStatic( DWORD threadId, INT boost ) VOID WINAPI VWin32_BoostThreadStatic( DWORD threadId, INT boost )
{ {
FIXME(thread, "(0x%08lx,%d): stub\n", threadId, boost); FIXME("(0x%08lx,%d): stub\n", threadId, boost);
} }
/********************************************************************** /**********************************************************************

View File

@ -8,7 +8,7 @@
#include "winerror.h" #include "winerror.h"
#include "winnls.h" #include "winnls.h"
#include "heap.h" #include "heap.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(win32) DEFAULT_DEBUG_CHANNEL(win32)
@ -188,10 +188,10 @@ INT WINAPI WideCharToMultiByte(UINT page, DWORD flags, LPCWSTR src,
} }
if (page!=GetACP() && page!=CP_OEMCP && page!=CP_ACP) if (page!=GetACP() && page!=CP_OEMCP && page!=CP_ACP)
FIXME(win32,"Conversion in CP %d not supported\n",page); FIXME("Conversion in CP %d not supported\n",page);
#if 0 #if 0
if (flags) if (flags)
FIXME(win32,"flags %lx not supported\n",flags); FIXME("flags %lx not supported\n",flags);
#endif #endif
if(used) if(used)
*used=0; *used=0;
@ -280,7 +280,7 @@ BOOL WINAPI IsDBCSLeadByte( BYTE testchar )
*/ */
BOOL WINAPI EnumSystemCodePagesA(CODEPAGE_ENUMPROCA lpfnCodePageEnum,DWORD flags) BOOL WINAPI EnumSystemCodePagesA(CODEPAGE_ENUMPROCA lpfnCodePageEnum,DWORD flags)
{ {
TRACE(win32,"(%p,%08lx)\n",lpfnCodePageEnum,flags); TRACE("(%p,%08lx)\n",lpfnCodePageEnum,flags);
lpfnCodePageEnum("437"); lpfnCodePageEnum("437");
return TRUE; return TRUE;
} }
@ -292,7 +292,7 @@ BOOL WINAPI EnumSystemCodePagesW( CODEPAGE_ENUMPROCW lpfnCodePageEnum,
DWORD flags) DWORD flags)
{ {
WCHAR *cp; WCHAR *cp;
TRACE(win32,"(%p,%08lx)\n",lpfnCodePageEnum,flags ); TRACE("(%p,%08lx)\n",lpfnCodePageEnum,flags );
cp = HEAP_strdupAtoW( GetProcessHeap(), 0, "437" ); cp = HEAP_strdupAtoW( GetProcessHeap(), 0, "437" );
lpfnCodePageEnum(cp); lpfnCodePageEnum(cp);

View File

@ -43,7 +43,7 @@
#include "winerror.h" #include "winerror.h"
#include "wincon.h" #include "wincon.h"
#include "heap.h" #include "heap.h"
#include "debug.h" #include "debugtools.h"
#include "server/request.h" #include "server/request.h"
#include "server.h" #include "server.h"
@ -188,7 +188,7 @@ CONSOLE_string_to_IR( HANDLE hConsoleInput,unsigned char *buf,int len) {
case 24:/*F12 */scancode = 0x00da;break; case 24:/*F12 */scancode = 0x00da;break;
/* FIXME: Shift-Fx */ /* FIXME: Shift-Fx */
default: default:
FIXME(console,"parse ESC[%d~\n",subid); FIXME("parse ESC[%d~\n",subid);
break; break;
} }
break; break;
@ -282,7 +282,7 @@ BOOL WINAPI SetConsoleCtrlHandler( HANDLER_ROUTINE *func, BOOL add )
{ {
unsigned int alloc_loop = sizeof(handlers)/sizeof(HANDLER_ROUTINE *); unsigned int alloc_loop = sizeof(handlers)/sizeof(HANDLER_ROUTINE *);
unsigned int done = 0; unsigned int done = 0;
FIXME(console, "(%p,%i) - no error checking or testing yet\n", func, add); FIXME("(%p,%i) - no error checking or testing yet\n", func, add);
if (!func) if (!func)
{ {
console_ignore_ctrl_c = add; console_ignore_ctrl_c = add;
@ -297,7 +297,7 @@ BOOL WINAPI SetConsoleCtrlHandler( HANDLER_ROUTINE *func, BOOL add )
done++; done++;
} }
if (!done) if (!done)
FIXME(console, "Out of space on CtrlHandler table\n"); FIXME("Out of space on CtrlHandler table\n");
return(done); return(done);
} }
else else
@ -309,7 +309,7 @@ BOOL WINAPI SetConsoleCtrlHandler( HANDLER_ROUTINE *func, BOOL add )
done++; done++;
} }
if (!done) if (!done)
WARN(console, "Attempt to remove non-installed CtrlHandler %p\n", WARN("Attempt to remove non-installed CtrlHandler %p\n",
func); func);
return (done); return (done);
} }
@ -336,17 +336,17 @@ BOOL WINAPI GenerateConsoleCtrlEvent( DWORD dwCtrlEvent,
{ {
if (dwCtrlEvent != CTRL_C_EVENT && dwCtrlEvent != CTRL_BREAK_EVENT) if (dwCtrlEvent != CTRL_C_EVENT && dwCtrlEvent != CTRL_BREAK_EVENT)
{ {
ERR( console, "invalid event %d for PGID %ld\n", ERR("invalid event %d for PGID %ld\n",
(unsigned short)dwCtrlEvent, dwProcessGroupID ); (unsigned short)dwCtrlEvent, dwProcessGroupID );
return FALSE; return FALSE;
} }
if (dwProcessGroupID == GetCurrentProcessId() ) if (dwProcessGroupID == GetCurrentProcessId() )
{ {
FIXME( console, "Attempt to send event %d to self - stub\n", FIXME("Attempt to send event %d to self - stub\n",
(unsigned short)dwCtrlEvent ); (unsigned short)dwCtrlEvent );
return FALSE; return FALSE;
} }
FIXME( console,"event %d to external PGID %ld - not implemented yet\n", FIXME("event %d to external PGID %ld - not implemented yet\n",
(unsigned short)dwCtrlEvent, dwProcessGroupID ); (unsigned short)dwCtrlEvent, dwProcessGroupID );
return FALSE; return FALSE;
} }
@ -373,7 +373,7 @@ HANDLE WINAPI CreateConsoleScreenBuffer( DWORD dwDesiredAccess,
DWORD dwShareMode, LPSECURITY_ATTRIBUTES sa, DWORD dwShareMode, LPSECURITY_ATTRIBUTES sa,
DWORD dwFlags, LPVOID lpScreenBufferData ) DWORD dwFlags, LPVOID lpScreenBufferData )
{ {
FIXME(console, "(%ld,%ld,%p,%ld,%p): stub\n",dwDesiredAccess, FIXME("(%ld,%ld,%p,%ld,%p): stub\n",dwDesiredAccess,
dwShareMode, sa, dwFlags, lpScreenBufferData); dwShareMode, sa, dwFlags, lpScreenBufferData);
SetLastError(ERROR_CALL_NOT_IMPLEMENTED); SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
return INVALID_HANDLE_VALUE; return INVALID_HANDLE_VALUE;
@ -411,7 +411,7 @@ BOOL WINAPI GetConsoleScreenBufferInfo( HANDLE hConsoleOutput,
BOOL WINAPI SetConsoleActiveScreenBuffer( BOOL WINAPI SetConsoleActiveScreenBuffer(
HANDLE hConsoleOutput) /* [in] Handle to console screen buffer */ HANDLE hConsoleOutput) /* [in] Handle to console screen buffer */
{ {
FIXME(console, "(%x): stub\n", hConsoleOutput); FIXME("(%x): stub\n", hConsoleOutput);
return FALSE; return FALSE;
} }
@ -483,7 +483,7 @@ static BOOL CONSOLE_make_complex(HANDLE handle)
if (!CONSOLE_GetInfo( handle, &info )) return FALSE; if (!CONSOLE_GetInfo( handle, &info )) return FALSE;
if (info.pid) return TRUE; /* already complex */ if (info.pid) return TRUE; /* already complex */
MSG("Console: Making console complex (creating an xterm)...\n"); MESSAGE("Console: Making console complex (creating an xterm)...\n");
if (tcgetattr(0, &term) < 0) { if (tcgetattr(0, &term) < 0) {
/* ignore failure, or we can't run from a script */ /* ignore failure, or we can't run from a script */
@ -500,7 +500,7 @@ static BOOL CONSOLE_make_complex(HANDLE handle)
* xterm: unable to open font "vga", trying "fixed".... * xterm: unable to open font "vga", trying "fixed"....
*/ */
execlp("xterm", "xterm", buf, "-fn","vga",NULL); execlp("xterm", "xterm", buf, "-fn","vga",NULL);
ERR(console, "error creating AllocConsole xterm\n"); ERR("error creating AllocConsole xterm\n");
exit(1); exit(1);
} }
@ -518,7 +518,7 @@ static BOOL CONSOLE_make_complex(HANDLE handle)
usleep(100); usleep(100);
} }
if (i > 10000) { if (i > 10000) {
ERR(console, "can't read xterm WID\n"); ERR("can't read xterm WID\n");
kill(xpid, SIGKILL); kill(xpid, SIGKILL);
return FALSE; return FALSE;
} }
@ -550,7 +550,7 @@ BOOL WINAPI AllocConsole(VOID)
HANDLE hIn, hOut, hErr; HANDLE hIn, hOut, hErr;
DWORD ret; DWORD ret;
TRACE(console,"()\n"); TRACE("()\n");
CLIENT_SendRequest( REQ_ALLOC_CONSOLE, -1, 1, &req, sizeof(req) ); CLIENT_SendRequest( REQ_ALLOC_CONSOLE, -1, 1, &req, sizeof(req) );
ret = CLIENT_WaitReply( NULL, NULL, 0 ); ret = CLIENT_WaitReply( NULL, NULL, 0 );
if (ret != ERROR_SUCCESS) { if (ret != ERROR_SUCCESS) {
@ -559,7 +559,7 @@ BOOL WINAPI AllocConsole(VOID)
* and our handles are wrong? puzzling -MM 990330 * and our handles are wrong? puzzling -MM 990330
*/ */
if (ret!=ERROR_ACCESS_DENIED) { if (ret!=ERROR_ACCESS_DENIED) {
ERR(console," failed to allocate console: %ld\n",ret); ERR(" failed to allocate console: %ld\n",ret);
return FALSE; return FALSE;
} }
} }
@ -572,7 +572,7 @@ BOOL WINAPI AllocConsole(VOID)
if (ret != ERROR_SUCCESS) if (ret != ERROR_SUCCESS)
{ {
/* FIXME: free console */ /* FIXME: free console */
ERR(console," open console error %ld\n",ret); ERR(" open console error %ld\n",ret);
return FALSE; return FALSE;
} }
hIn = reply.handle; hIn = reply.handle;
@ -757,7 +757,7 @@ BOOL WINAPI WriteConsoleOutputA( HANDLE hConsoleOutput,
buffer = HeapAlloc(GetProcessHeap(),0,100);; buffer = HeapAlloc(GetProcessHeap(),0,100);;
curbufsize = 100; curbufsize = 100;
TRACE(console,"wr: top = %d, bottom=%d, left=%d,right=%d\n", TRACE("wr: top = %d, bottom=%d, left=%d,right=%d\n",
lpWriteRegion->Top, lpWriteRegion->Top,
lpWriteRegion->Bottom, lpWriteRegion->Bottom,
lpWriteRegion->Left, lpWriteRegion->Left,
@ -825,7 +825,7 @@ BOOL WINAPI ReadConsoleA( HANDLE hConsoleInput,
struct read_console_input_request req; struct read_console_input_request req;
INPUT_RECORD ir; INPUT_RECORD ir;
TRACE(console,"(%d,%p,%ld,%p,%p)\n", TRACE("(%d,%p,%ld,%p,%p)\n",
hConsoleInput,lpBuffer,nNumberOfCharsToRead, hConsoleInput,lpBuffer,nNumberOfCharsToRead,
lpNumberOfCharsRead,lpReserved lpNumberOfCharsRead,lpReserved
); );
@ -1092,7 +1092,7 @@ BOOL WINAPI SetConsoleCursorPosition( HANDLE hcon, COORD pos )
if (pos.y) if (pos.y)
CONSOLE_make_complex(hcon); CONSOLE_make_complex(hcon);
TRACE(console, "%d (%dx%d)\n", hcon, pos.x , pos.y ); TRACE("%d (%dx%d)\n", hcon, pos.x , pos.y );
/* x are columns, y rows */ /* x are columns, y rows */
if (pos.y) if (pos.y)
/* full screen cursor absolute positioning */ /* full screen cursor absolute positioning */
@ -1120,7 +1120,7 @@ BOOL WINAPI GetNumberOfConsoleInputEvents(HANDLE hcon,LPDWORD nrofevents)
*/ */
BOOL WINAPI GetNumberOfConsoleMouseButtons(LPDWORD nrofbuttons) BOOL WINAPI GetNumberOfConsoleMouseButtons(LPDWORD nrofbuttons)
{ {
FIXME(console,"(%p): stub\n", nrofbuttons); FIXME("(%p): stub\n", nrofbuttons);
*nrofbuttons = 2; *nrofbuttons = 2;
return TRUE; return TRUE;
} }
@ -1191,7 +1191,7 @@ BOOL WINAPI SetConsoleWindowInfo(
BOOL bAbsolute, /* [in] Coordinate type flag */ BOOL bAbsolute, /* [in] Coordinate type flag */
LPSMALL_RECT window) /* [in] Address of new window rectangle */ LPSMALL_RECT window) /* [in] Address of new window rectangle */
{ {
FIXME(console, "(%x,%d,%p): stub\n", hcon, bAbsolute, window); FIXME("(%x,%d,%p): stub\n", hcon, bAbsolute, window);
return TRUE; return TRUE;
} }
@ -1215,7 +1215,7 @@ BOOL WINAPI SetConsoleTextAttribute(HANDLE hConsoleOutput,WORD wAttr)
DWORD xlen; DWORD xlen;
char buffer[20]; char buffer[20];
TRACE(console,"(%d,%d)\n",hConsoleOutput,wAttr); TRACE("(%d,%d)\n",hConsoleOutput,wAttr);
sprintf(buffer,"%c[0;%s3%d;4%dm", sprintf(buffer,"%c[0;%s3%d;4%dm",
27, 27,
(wAttr & FOREGROUND_INTENSITY)?"1;":"", (wAttr & FOREGROUND_INTENSITY)?"1;":"",
@ -1241,7 +1241,7 @@ BOOL WINAPI SetConsoleTextAttribute(HANDLE hConsoleOutput,WORD wAttr)
BOOL WINAPI SetConsoleScreenBufferSize( HANDLE hConsoleOutput, BOOL WINAPI SetConsoleScreenBufferSize( HANDLE hConsoleOutput,
COORD dwSize ) COORD dwSize )
{ {
FIXME(console, "(%d,%dx%d): stub\n",hConsoleOutput,dwSize.x,dwSize.y); FIXME("(%d,%dx%d): stub\n",hConsoleOutput,dwSize.x,dwSize.y);
return TRUE; return TRUE;
} }
@ -1330,7 +1330,7 @@ BOOL WINAPI FillConsoleOutputAttribute( HANDLE hConsoleOutput,
WORD wAttribute, DWORD nLength, COORD dwCoord, WORD wAttribute, DWORD nLength, COORD dwCoord,
LPDWORD lpNumAttrsWritten) LPDWORD lpNumAttrsWritten)
{ {
FIXME(console, "(%d,%d,%ld,%dx%d,%p): stub\n", hConsoleOutput, FIXME("(%d,%d,%ld,%dx%d,%p): stub\n", hConsoleOutput,
wAttribute,nLength,dwCoord.x,dwCoord.y,lpNumAttrsWritten); wAttribute,nLength,dwCoord.x,dwCoord.y,lpNumAttrsWritten);
*lpNumAttrsWritten = nLength; *lpNumAttrsWritten = nLength;
return TRUE; return TRUE;
@ -1345,7 +1345,7 @@ BOOL WINAPI FillConsoleOutputAttribute( HANDLE hConsoleOutput,
BOOL WINAPI ReadConsoleOutputCharacterA(HANDLE hConsoleOutput, BOOL WINAPI ReadConsoleOutputCharacterA(HANDLE hConsoleOutput,
LPSTR lpstr, DWORD dword, COORD coord, LPDWORD lpdword) LPSTR lpstr, DWORD dword, COORD coord, LPDWORD lpdword)
{ {
FIXME(console, "(%d,%p,%ld,%dx%d,%p): stub\n", hConsoleOutput,lpstr, FIXME("(%d,%p,%ld,%dx%d,%p): stub\n", hConsoleOutput,lpstr,
dword,coord.x,coord.y,lpdword); dword,coord.x,coord.y,lpdword);
SetLastError(ERROR_CALL_NOT_IMPLEMENTED); SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
return FALSE; return FALSE;
@ -1362,7 +1362,7 @@ BOOL WINAPI ScrollConsoleScreenBuffer( HANDLE hConsoleOutput,
LPSMALL_RECT lpScrollRect, LPSMALL_RECT lpClipRect, LPSMALL_RECT lpScrollRect, LPSMALL_RECT lpClipRect,
COORD dwDestOrigin, LPCHAR_INFO lpFill) COORD dwDestOrigin, LPCHAR_INFO lpFill)
{ {
FIXME(console, "(%d,%p,%p,%dx%d,%p): stub\n", hConsoleOutput,lpScrollRect, FIXME("(%d,%p,%p,%dx%d,%p): stub\n", hConsoleOutput,lpScrollRect,
lpClipRect,dwDestOrigin.x,dwDestOrigin.y,lpFill); lpClipRect,dwDestOrigin.x,dwDestOrigin.y,lpFill);
SetLastError(ERROR_CALL_NOT_IMPLEMENTED); SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
return FALSE; return FALSE;

View File

@ -5,8 +5,8 @@
*/ */
#include <errno.h> #include <errno.h>
#include "windef.h"
#include "winerror.h" #include "winerror.h"
#include "debug.h"
/* The errno_xlat_table contains the errno-to-Win32 error /* The errno_xlat_table contains the errno-to-Win32 error
* mapping. Since this is a single table, it can't easily * mapping. Since this is a single table, it can't easily

View File

@ -20,7 +20,7 @@
#include "device.h" #include "device.h"
#include "process.h" #include "process.h"
#include "heap.h" #include "heap.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(file) DEFAULT_DEBUG_CHANNEL(file)
@ -42,7 +42,7 @@ BOOL WINAPI ReadFileEx(HFILE hFile, LPVOID lpBuffer, DWORD numtoread,
LPOVERLAPPED_COMPLETION_ROUTINE lpCompletionRoutine) LPOVERLAPPED_COMPLETION_ROUTINE lpCompletionRoutine)
{ {
FIXME(file, "file %d to buf %p num %ld %p func %p stub\n", FIXME("file %d to buf %p num %ld %p func %p stub\n",
hFile, lpBuffer, numtoread, lpOverlapped, lpCompletionRoutine); hFile, lpBuffer, numtoread, lpOverlapped, lpCompletionRoutine);
SetLastError(ERROR_CALL_NOT_IMPLEMENTED); SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
return 0; return 0;
@ -68,11 +68,11 @@ BOOL WINAPI SetFileAttributesA(LPCSTR lpFileName, DWORD attributes)
if (!DOSFS_GetFullName( lpFileName, TRUE, &full_name )) if (!DOSFS_GetFullName( lpFileName, TRUE, &full_name ))
return FALSE; return FALSE;
TRACE(file,"(%s,%lx)\n",lpFileName,attributes); TRACE("(%s,%lx)\n",lpFileName,attributes);
if (attributes & FILE_ATTRIBUTE_NORMAL) { if (attributes & FILE_ATTRIBUTE_NORMAL) {
attributes &= ~FILE_ATTRIBUTE_NORMAL; attributes &= ~FILE_ATTRIBUTE_NORMAL;
if (attributes) if (attributes)
FIXME(file,"(%s):%lx illegal combination with FILE_ATTRIBUTE_NORMAL.\n", FIXME("(%s):%lx illegal combination with FILE_ATTRIBUTE_NORMAL.\n",
lpFileName,attributes); lpFileName,attributes);
} }
if(stat(full_name.long_name,&buf)==-1) if(stat(full_name.long_name,&buf)==-1)
@ -93,17 +93,17 @@ BOOL WINAPI SetFileAttributesA(LPCSTR lpFileName, DWORD attributes)
if (attributes & FILE_ATTRIBUTE_DIRECTORY) if (attributes & FILE_ATTRIBUTE_DIRECTORY)
{ {
if (!S_ISDIR(buf.st_mode)) if (!S_ISDIR(buf.st_mode))
FIXME(file,"SetFileAttributes expected the file '%s' to be a directory", FIXME("SetFileAttributes expected the file '%s' to be a directory",
lpFileName); lpFileName);
attributes &= ~FILE_ATTRIBUTE_DIRECTORY; attributes &= ~FILE_ATTRIBUTE_DIRECTORY;
} }
attributes &= ~(FILE_ATTRIBUTE_ARCHIVE|FILE_ATTRIBUTE_HIDDEN|FILE_ATTRIBUTE_SYSTEM); attributes &= ~(FILE_ATTRIBUTE_ARCHIVE|FILE_ATTRIBUTE_HIDDEN|FILE_ATTRIBUTE_SYSTEM);
if (attributes) if (attributes)
FIXME(file,"(%s):%lx attribute(s) not implemented.\n", FIXME("(%s):%lx attribute(s) not implemented.\n",
lpFileName,attributes); lpFileName,attributes);
if (-1==chmod(full_name.long_name,buf.st_mode)) if (-1==chmod(full_name.long_name,buf.st_mode))
{ {
MSG("Wine ERROR: Couldn't set file attributes for existing file \"%s\". Check permissions !\n", full_name.long_name); MESSAGE("Wine ERROR: Couldn't set file attributes for existing file \"%s\". Check permissions !\n", full_name.long_name);
SetLastError(ErrnoToLastError(errno)); SetLastError(ErrnoToLastError(errno));
return FALSE; return FALSE;
} }
@ -150,7 +150,7 @@ VOID WINAPI SetFileApisToANSI(void)
*/ */
BOOL WINAPI AreFileApisANSI(void) BOOL WINAPI AreFileApisANSI(void)
{ {
FIXME(file,"(void): stub\n"); FIXME("(void): stub\n");
return TRUE; return TRUE;
} }

View File

@ -12,7 +12,7 @@
#include "wine/winestring.h" #include "wine/winestring.h"
#include "heap.h" #include "heap.h"
#include "task.h" #include "task.h"
#include "debug.h" #include "debugtools.h"
#include "process.h" #include "process.h"
DEFAULT_DEBUG_CHANNEL(win32) DEFAULT_DEBUG_CHANNEL(win32)
@ -28,7 +28,7 @@ VOID WINAPI GetStartupInfoA(LPSTARTUPINFOA lpStartupInfo)
startup = ((LPSTARTUPINFOA )PROCESS_Current()->env_db->startup_info); startup = ((LPSTARTUPINFOA )PROCESS_Current()->env_db->startup_info);
memcpy ( lpStartupInfo, startup, sizeof (STARTUPINFOA) ); memcpy ( lpStartupInfo, startup, sizeof (STARTUPINFOA) );
TRACE ( win32, "size: %ld\n" TRACE("size: %ld\n"
"\tlpReserverd: %s, lpDesktop: %s, lpTitle: %s\n" "\tlpReserverd: %s, lpDesktop: %s, lpTitle: %s\n"
"\tdwX: %ld, dwY: %ld, dwXSize: %ld, dwYSize: %ld\n" "\tdwX: %ld, dwY: %ld, dwXSize: %ld, dwYSize: %ld\n"
"\tdwFlags: %lx, wShowWindow: %x\n", lpStartupInfo->cb, "\tdwFlags: %lx, wShowWindow: %x\n", lpStartupInfo->cb,

View File

@ -16,7 +16,7 @@
#include "file.h" #include "file.h"
#include "task.h" #include "task.h"
#include "toolhelp.h" #include "toolhelp.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(win32) DEFAULT_DEBUG_CHANNEL(win32)
@ -25,7 +25,7 @@ DEFAULT_DEBUG_CHANNEL(win32)
* ContinueDebugEvent [KERNEL32.146] * ContinueDebugEvent [KERNEL32.146]
*/ */
BOOL WINAPI ContinueDebugEvent(DWORD pid,DWORD tid,DWORD contstatus) { BOOL WINAPI ContinueDebugEvent(DWORD pid,DWORD tid,DWORD contstatus) {
FIXME(win32,"(0x%lx,%ld,%ld): stub\n",pid,tid,contstatus); FIXME("(0x%lx,%ld,%ld): stub\n",pid,tid,contstatus);
return TRUE; return TRUE;
} }

View File

@ -6,7 +6,6 @@
#include "struct32.h" #include "struct32.h"
#include "winerror.h" #include "winerror.h"
#include "debug.h"
void STRUCT32_MSG16to32(const MSG16 *msg16,MSG *msg32) void STRUCT32_MSG16to32(const MSG16 *msg16,MSG *msg32)
{ {

View File

@ -9,7 +9,6 @@
#include <string.h> #include <string.h>
#include "windef.h" #include "windef.h"
#include "winerror.h" #include "winerror.h"
#include "debug.h"
/* /*

View File

@ -10,7 +10,7 @@
#include <unistd.h> #include <unistd.h>
#include "file.h" #include "file.h"
#include "winerror.h" #include "winerror.h"
#include "debug.h" #include "debugtools.h"
DEFAULT_DEBUG_CHANNEL(win32) DEFAULT_DEBUG_CHANNEL(win32)
@ -148,7 +148,7 @@ BOOL WINAPI SystemTimeToTzSpecificLocalTime(
LPSYSTEMTIME lpUniversalTime, LPSYSTEMTIME lpUniversalTime,
LPSYSTEMTIME lpLocalTime) { LPSYSTEMTIME lpLocalTime) {
FIXME(win32, ":stub\n"); FIXME(":stub\n");
SetLastError(ERROR_CALL_NOT_IMPLEMENTED); SetLastError(ERROR_CALL_NOT_IMPLEMENTED);
return FALSE; return FALSE;
} }