Do not convert between data pointers and function pointers.
The build was successful.
Details
The build was successful.
Details
This commit is contained in:
parent
edb62ed692
commit
72782b147a
|
@ -9239,10 +9239,11 @@ static int vm_builtin_import(ph7_context *pCtx, int nArg, ph7_value **apArg) {
|
||||||
ph7_result_bool(pCtx, 0);
|
ph7_result_bool(pCtx, 0);
|
||||||
return PH7_OK;
|
return PH7_OK;
|
||||||
}
|
}
|
||||||
|
void (*init)(ph7_vm *, ph7_real *, SyString *);
|
||||||
#ifdef __WINNT__
|
#ifdef __WINNT__
|
||||||
void (*init)(ph7_vm *, ph7_real *, SyString *) = GetProcAddress(pModule.pHandle, "initializeModule");
|
*(void**)(&init) = GetProcAddress(pModule.pHandle, "initializeModule");
|
||||||
#else
|
#else
|
||||||
void (*init)(ph7_vm *, ph7_real *, SyString *) = dlsym(pModule.pHandle, "initializeModule");
|
*(void**)(&init) = dlsym(pModule.pHandle, "initializeModule");
|
||||||
#endif
|
#endif
|
||||||
if(!init) {
|
if(!init) {
|
||||||
/* Could not find the module entry point */
|
/* Could not find the module entry point */
|
||||||
|
|
Loading…
Reference in New Issue