committed patch for correct typecasting
This commit is contained in:
parent
bf8cf574e0
commit
a43a3b0803
@ -288,7 +288,7 @@ static cell AMX_NATIVE_CALL invalid_native(AMX *amx, cell *params)
|
|||||||
}
|
}
|
||||||
|
|
||||||
char name[sNAMEMAX + 1];
|
char name[sNAMEMAX + 1];
|
||||||
int native = (int)(amx->usertags[UT_NATIVE]);
|
int native = (int)(_INT_PTR)(amx->usertags[UT_NATIVE]);
|
||||||
int err = amx_GetNative(amx, native, name);
|
int err = amx_GetNative(amx, native, name);
|
||||||
|
|
||||||
if (err != AMX_ERR_NONE)
|
if (err != AMX_ERR_NONE)
|
||||||
|
@ -88,6 +88,17 @@ extern AMX_NATIVE_INFO vault_Natives[];
|
|||||||
#define DLFREE(m) dlclose(m)
|
#define DLFREE(m) dlclose(m)
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#if defined __GNUC__
|
||||||
|
#include <stdint.h>
|
||||||
|
typedef intptr_t _INT_PTR;
|
||||||
|
#else
|
||||||
|
#if defined AMD64
|
||||||
|
typedef __int64 _INT_PTR;
|
||||||
|
#else
|
||||||
|
typedef __int32 _INT_PTR;
|
||||||
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifndef __linux__
|
#ifndef __linux__
|
||||||
typedef HINSTANCE DLHANDLE;
|
typedef HINSTANCE DLHANDLE;
|
||||||
#else
|
#else
|
||||||
|
@ -395,7 +395,7 @@ int Debugger::FormatError(char *buffer, size_t maxLength)
|
|||||||
num = (int)*p_cip;
|
num = (int)*p_cip;
|
||||||
}*/
|
}*/
|
||||||
//New code only requires this...
|
//New code only requires this...
|
||||||
num = (int)m_pAmx->usertags[UT_NATIVE];
|
num = (int)(_INT_PTR)m_pAmx->usertags[UT_NATIVE];
|
||||||
amx_err = amx_GetNative(m_pAmx, num, native_name);
|
amx_err = amx_GetNative(m_pAmx, num, native_name);
|
||||||
/*if (num)
|
/*if (num)
|
||||||
amx_err = amx_GetNative(m_pAmx, (int)*p_cip, native_name);
|
amx_err = amx_GetNative(m_pAmx, (int)*p_cip, native_name);
|
||||||
|
Loading…
Reference in New Issue
Block a user