warning C4273: 'MyTextOutW' : inconsistent dll linkage
I am developing the hooker in windows xp using Visual Studio 2010,
I have linked all kernel32.dll, user32.lib, advapi32.lib.... from the 7.0a sdk
By definition, WINGDIAPI is just __declspec(dllimport)
The original prototype is
They just match each other, why does the warning occur?
Thanks
Jack
I am developing the hooker in windows xp using Visual Studio 2010,
I have linked all kernel32.dll, user32.lib, advapi32.lib.... from the 7.0a sdk
By definition, WINGDIAPI is just __declspec(dllimport)
The original prototype is
Code:
__gdi_entry WINGDIAPI BOOL WINAPI TextOutA( __in HDC hdc, __in int x, __in int y, __in_ecount(c) LPCSTR lpString, __in int c);Thanks
Jack
Code:
WINGDIAPI BOOL WINAPI MyTextOutA(HDC, int, int, LPCSTR, int);
BOOL WINAPI MyTextOutA(HDC hDC, int a, int b, LPCSTR str, int c)
{
std::string s("TextOutA called");
logfile.write(s.c_str(), s.length());
return ::TextOutA(hDC, a, b, "Hooked text", 11);
}