mirror of
https://gitea.tendokyu.moe/Dniel97/segatools.git
synced 2025-02-19 20:11:42 +01:00
Fix function pointer calling convention syntax
Fixes MSVC build
This commit is contained in:
parent
de134877a6
commit
46e5c6127d
@ -34,11 +34,11 @@ static void * WINAPI hook_GetProcAddress(HMODULE mod, const char *name);
|
|||||||
|
|
||||||
/* Link pointers */
|
/* Link pointers */
|
||||||
|
|
||||||
static HMODULE WINAPI (*next_GetModuleHandleA)(const char *name);
|
static HMODULE (WINAPI *next_GetModuleHandleA)(const char *name);
|
||||||
static HMODULE WINAPI (*next_GetModuleHandleW)(const wchar_t *name);
|
static HMODULE (WINAPI *next_GetModuleHandleW)(const wchar_t *name);
|
||||||
static HMODULE WINAPI (*next_LoadLibraryA)(const char *name);
|
static HMODULE (WINAPI *next_LoadLibraryA)(const char *name);
|
||||||
static HMODULE WINAPI (*next_LoadLibraryW)(const wchar_t *name);
|
static HMODULE (WINAPI *next_LoadLibraryW)(const wchar_t *name);
|
||||||
static void * WINAPI (*next_GetProcAddress)(HMODULE mod, const char *name);
|
static void * (WINAPI *next_GetProcAddress)(HMODULE mod, const char *name);
|
||||||
|
|
||||||
static const struct hook_symbol dll_loader_syms[] = {
|
static const struct hook_symbol dll_loader_syms[] = {
|
||||||
{
|
{
|
||||||
|
@ -68,7 +68,7 @@ static int WSAAPI hook_getaddrinfo(
|
|||||||
|
|
||||||
/* Link pointers */
|
/* Link pointers */
|
||||||
|
|
||||||
static DNS_STATUS WINAPI (*next_DnsQuery_A)(
|
static DNS_STATUS (WINAPI *next_DnsQuery_A)(
|
||||||
const char *pszName,
|
const char *pszName,
|
||||||
WORD wType,
|
WORD wType,
|
||||||
DWORD Options,
|
DWORD Options,
|
||||||
@ -76,7 +76,7 @@ static DNS_STATUS WINAPI (*next_DnsQuery_A)(
|
|||||||
DNS_RECORD **ppQueryResults,
|
DNS_RECORD **ppQueryResults,
|
||||||
void *pReserved);
|
void *pReserved);
|
||||||
|
|
||||||
static DNS_STATUS WINAPI (*next_DnsQuery_W)(
|
static DNS_STATUS (WINAPI *next_DnsQuery_W)(
|
||||||
const wchar_t *pszName,
|
const wchar_t *pszName,
|
||||||
WORD wType,
|
WORD wType,
|
||||||
DWORD Options,
|
DWORD Options,
|
||||||
@ -84,12 +84,12 @@ static DNS_STATUS WINAPI (*next_DnsQuery_W)(
|
|||||||
DNS_RECORD **ppQueryResults,
|
DNS_RECORD **ppQueryResults,
|
||||||
void *pReserved);
|
void *pReserved);
|
||||||
|
|
||||||
static DNS_STATUS WINAPI (*next_DnsQueryEx)(
|
static DNS_STATUS (WINAPI *next_DnsQueryEx)(
|
||||||
POLYFILL_DNS_QUERY_REQUEST *pRequest,
|
POLYFILL_DNS_QUERY_REQUEST *pRequest,
|
||||||
void *pQueryResults,
|
void *pQueryResults,
|
||||||
void *pCancelHandle);
|
void *pCancelHandle);
|
||||||
|
|
||||||
static int WSAAPI (*next_getaddrinfo)(
|
static int (WSAAPI *next_getaddrinfo)(
|
||||||
const char *pNodeName,
|
const char *pNodeName,
|
||||||
const char *pServiceName,
|
const char *pServiceName,
|
||||||
const ADDRINFOA *pHints,
|
const ADDRINFOA *pHints,
|
||||||
|
@ -77,15 +77,15 @@ static BOOL WINAPI hook_GetFileAttributesExW(
|
|||||||
|
|
||||||
/* Link pointers */
|
/* Link pointers */
|
||||||
|
|
||||||
static BOOL WINAPI (*next_CreateDirectoryA)(
|
static BOOL (WINAPI *next_CreateDirectoryA)(
|
||||||
const char *lpFileName,
|
const char *lpFileName,
|
||||||
SECURITY_ATTRIBUTES *lpSecurityAttributes);
|
SECURITY_ATTRIBUTES *lpSecurityAttributes);
|
||||||
|
|
||||||
static BOOL WINAPI (*next_CreateDirectoryW)(
|
static BOOL (WINAPI *next_CreateDirectoryW)(
|
||||||
const wchar_t *lpFileName,
|
const wchar_t *lpFileName,
|
||||||
SECURITY_ATTRIBUTES *lpSecurityAttributes);
|
SECURITY_ATTRIBUTES *lpSecurityAttributes);
|
||||||
|
|
||||||
static HANDLE WINAPI (*next_CreateFileA)(
|
static HANDLE (WINAPI *next_CreateFileA)(
|
||||||
const char *lpFileName,
|
const char *lpFileName,
|
||||||
uint32_t dwDesiredAccess,
|
uint32_t dwDesiredAccess,
|
||||||
uint32_t dwShareMode,
|
uint32_t dwShareMode,
|
||||||
@ -94,7 +94,7 @@ static HANDLE WINAPI (*next_CreateFileA)(
|
|||||||
uint32_t dwFlagsAndAttributes,
|
uint32_t dwFlagsAndAttributes,
|
||||||
HANDLE hTemplateFile);
|
HANDLE hTemplateFile);
|
||||||
|
|
||||||
static HANDLE WINAPI (*next_CreateFileW)(
|
static HANDLE (WINAPI *next_CreateFileW)(
|
||||||
const wchar_t *lpFileName,
|
const wchar_t *lpFileName,
|
||||||
uint32_t dwDesiredAccess,
|
uint32_t dwDesiredAccess,
|
||||||
uint32_t dwShareMode,
|
uint32_t dwShareMode,
|
||||||
@ -103,7 +103,7 @@ static HANDLE WINAPI (*next_CreateFileW)(
|
|||||||
uint32_t dwFlagsAndAttributes,
|
uint32_t dwFlagsAndAttributes,
|
||||||
HANDLE hTemplateFile);
|
HANDLE hTemplateFile);
|
||||||
|
|
||||||
static HANDLE WINAPI (*next_FindFirstFileExA)(
|
static HANDLE (WINAPI *next_FindFirstFileExA)(
|
||||||
const char *lpFileName,
|
const char *lpFileName,
|
||||||
FINDEX_INFO_LEVELS fInfoLevelId,
|
FINDEX_INFO_LEVELS fInfoLevelId,
|
||||||
void *lpFindFileData,
|
void *lpFindFileData,
|
||||||
@ -111,7 +111,7 @@ static HANDLE WINAPI (*next_FindFirstFileExA)(
|
|||||||
void *lpSearchFilter,
|
void *lpSearchFilter,
|
||||||
DWORD dwAdditionalFlags);
|
DWORD dwAdditionalFlags);
|
||||||
|
|
||||||
static HANDLE WINAPI (*next_FindFirstFileExW)(
|
static HANDLE (WINAPI *next_FindFirstFileExW)(
|
||||||
const wchar_t *lpFileName,
|
const wchar_t *lpFileName,
|
||||||
FINDEX_INFO_LEVELS fInfoLevelId,
|
FINDEX_INFO_LEVELS fInfoLevelId,
|
||||||
void *lpFindFileData,
|
void *lpFindFileData,
|
||||||
@ -119,16 +119,16 @@ static HANDLE WINAPI (*next_FindFirstFileExW)(
|
|||||||
void *lpSearchFilter,
|
void *lpSearchFilter,
|
||||||
DWORD dwAdditionalFlags);
|
DWORD dwAdditionalFlags);
|
||||||
|
|
||||||
static DWORD WINAPI (*next_GetFileAttributesA)(const char *lpFileName);
|
static DWORD (WINAPI *next_GetFileAttributesA)(const char *lpFileName);
|
||||||
|
|
||||||
static DWORD WINAPI (*next_GetFileAttributesW)(const wchar_t *lpFileName);
|
static DWORD (WINAPI *next_GetFileAttributesW)(const wchar_t *lpFileName);
|
||||||
|
|
||||||
static BOOL WINAPI (*next_GetFileAttributesExA)(
|
static BOOL (WINAPI *next_GetFileAttributesExA)(
|
||||||
const char *lpFileName,
|
const char *lpFileName,
|
||||||
GET_FILEEX_INFO_LEVELS fInfoLevelId,
|
GET_FILEEX_INFO_LEVELS fInfoLevelId,
|
||||||
void *lpFileInformation);
|
void *lpFileInformation);
|
||||||
|
|
||||||
static BOOL WINAPI (*next_GetFileAttributesExW)(
|
static BOOL (WINAPI *next_GetFileAttributesExW)(
|
||||||
const wchar_t *lpFileName,
|
const wchar_t *lpFileName,
|
||||||
GET_FILEEX_INFO_LEVELS fInfoLevelId,
|
GET_FILEEX_INFO_LEVELS fInfoLevelId,
|
||||||
void *lpFileInformation);
|
void *lpFileInformation);
|
||||||
|
@ -91,14 +91,14 @@ static LSTATUS WINAPI hook_RegSetValueExW(
|
|||||||
|
|
||||||
/* Link pointers */
|
/* Link pointers */
|
||||||
|
|
||||||
static LSTATUS WINAPI (*next_RegOpenKeyExW)(
|
static LSTATUS (WINAPI *next_RegOpenKeyExW)(
|
||||||
HKEY parent,
|
HKEY parent,
|
||||||
const wchar_t *name,
|
const wchar_t *name,
|
||||||
uint32_t flags,
|
uint32_t flags,
|
||||||
uint32_t access,
|
uint32_t access,
|
||||||
HKEY *out);
|
HKEY *out);
|
||||||
|
|
||||||
static LSTATUS WINAPI (*next_RegCreateKeyExW)(
|
static LSTATUS (WINAPI *next_RegCreateKeyExW)(
|
||||||
HKEY parent,
|
HKEY parent,
|
||||||
const wchar_t *name,
|
const wchar_t *name,
|
||||||
uint32_t reserved,
|
uint32_t reserved,
|
||||||
@ -109,9 +109,9 @@ static LSTATUS WINAPI (*next_RegCreateKeyExW)(
|
|||||||
HKEY *out,
|
HKEY *out,
|
||||||
uint32_t *disposition);
|
uint32_t *disposition);
|
||||||
|
|
||||||
static LSTATUS WINAPI (*next_RegCloseKey)(HKEY handle);
|
static LSTATUS (WINAPI *next_RegCloseKey)(HKEY handle);
|
||||||
|
|
||||||
static LSTATUS WINAPI (*next_RegQueryValueExA)(
|
static LSTATUS (WINAPI *next_RegQueryValueExA)(
|
||||||
HKEY handle,
|
HKEY handle,
|
||||||
const char *name,
|
const char *name,
|
||||||
void *reserved,
|
void *reserved,
|
||||||
@ -119,7 +119,7 @@ static LSTATUS WINAPI (*next_RegQueryValueExA)(
|
|||||||
void *bytes,
|
void *bytes,
|
||||||
uint32_t *nbytes);
|
uint32_t *nbytes);
|
||||||
|
|
||||||
static LSTATUS WINAPI (*next_RegQueryValueExW)(
|
static LSTATUS (WINAPI *next_RegQueryValueExW)(
|
||||||
HKEY handle,
|
HKEY handle,
|
||||||
const wchar_t *name,
|
const wchar_t *name,
|
||||||
void *reserved,
|
void *reserved,
|
||||||
@ -127,7 +127,7 @@ static LSTATUS WINAPI (*next_RegQueryValueExW)(
|
|||||||
void *bytes,
|
void *bytes,
|
||||||
uint32_t *nbytes);
|
uint32_t *nbytes);
|
||||||
|
|
||||||
static LSTATUS WINAPI (*next_RegSetValueExW)(
|
static LSTATUS (WINAPI *next_RegSetValueExW)(
|
||||||
HKEY handle,
|
HKEY handle,
|
||||||
const wchar_t *name,
|
const wchar_t *name,
|
||||||
uint32_t reserved,
|
uint32_t reserved,
|
||||||
|
@ -74,7 +74,7 @@ HRESULT idz_di_init(
|
|||||||
{
|
{
|
||||||
HRESULT hr;
|
HRESULT hr;
|
||||||
HMODULE dinput8;
|
HMODULE dinput8;
|
||||||
HRESULT WINAPI (*api_entry)(HINSTANCE,DWORD,REFIID,LPVOID *,LPUNKNOWN);
|
HRESULT (WINAPI *api_entry)(HINSTANCE,DWORD,REFIID,LPVOID *,LPUNKNOWN);
|
||||||
wchar_t dll_path[MAX_PATH];
|
wchar_t dll_path[MAX_PATH];
|
||||||
UINT path_pos;
|
UINT path_pos;
|
||||||
|
|
||||||
|
@ -68,28 +68,28 @@ static uint32_t WINAPI hook_IcmpSendEcho2(
|
|||||||
|
|
||||||
/* Link pointers */
|
/* Link pointers */
|
||||||
|
|
||||||
static uint32_t WINAPI (*next_GetAdaptersAddresses)(
|
static uint32_t (WINAPI *next_GetAdaptersAddresses)(
|
||||||
uint32_t Family,
|
uint32_t Family,
|
||||||
uint32_t Flags,
|
uint32_t Flags,
|
||||||
void *Reserved,
|
void *Reserved,
|
||||||
IP_ADAPTER_ADDRESSES *AdapterAddresses,
|
IP_ADAPTER_ADDRESSES *AdapterAddresses,
|
||||||
uint32_t *SizePointer);
|
uint32_t *SizePointer);
|
||||||
|
|
||||||
static uint32_t WINAPI (*next_GetAdaptersInfo)(
|
static uint32_t (WINAPI *next_GetAdaptersInfo)(
|
||||||
IP_ADAPTER_INFO *AdapterInfo,
|
IP_ADAPTER_INFO *AdapterInfo,
|
||||||
uint32_t *SizePointer);
|
uint32_t *SizePointer);
|
||||||
|
|
||||||
static uint32_t WINAPI (*next_GetBestRoute)(
|
static uint32_t (WINAPI *next_GetBestRoute)(
|
||||||
uint32_t src_ip,
|
uint32_t src_ip,
|
||||||
uint32_t dest_ip,
|
uint32_t dest_ip,
|
||||||
MIB_IPFORWARDROW *route);
|
MIB_IPFORWARDROW *route);
|
||||||
|
|
||||||
static uint32_t WINAPI (*next_GetIfTable)(
|
static uint32_t (WINAPI *next_GetIfTable)(
|
||||||
MIB_IFTABLE *pIfTable,
|
MIB_IFTABLE *pIfTable,
|
||||||
uint32_t *pdwSize,
|
uint32_t *pdwSize,
|
||||||
BOOL bOrder);
|
BOOL bOrder);
|
||||||
|
|
||||||
static uint32_t WINAPI (*next_IcmpSendEcho2)(
|
static uint32_t (WINAPI *next_IcmpSendEcho2)(
|
||||||
HANDLE IcmpHandle,
|
HANDLE IcmpHandle,
|
||||||
HANDLE Event,
|
HANDLE Event,
|
||||||
PIO_APC_ROUTINE ApcRoutine,
|
PIO_APC_ROUTINE ApcRoutine,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user