about summary refs log tree commit diff stats
path: root/src/wrapped
diff options
context:
space:
mode:
authorYang Liu <liuyang22@iscas.ac.cn>2025-06-18 23:13:34 +0800
committerGitHub <noreply@github.com>2025-06-18 17:13:34 +0200
commitc96c1ad5ddb977a3723b6d53317f7942546e0779 (patch)
treefa2ea910ed9cca3806de8a1020b4e0d4e78ef41f /src/wrapped
parent71220b7fef4466f98cc78b1d013755aca8e217c6 (diff)
downloadbox64-c96c1ad5ddb977a3723b6d53317f7942546e0779.tar.gz
box64-c96c1ad5ddb977a3723b6d53317f7942546e0779.zip
[BIONIC] Fixed some compilation warnings (#2756)
Diffstat (limited to 'src/wrapped')
-rw-r--r--src/wrapped/generated/functions_list.txt1
-rw-r--r--src/wrapped/wrappedgio2.c6
-rw-r--r--src/wrapped/wrappedopenal.c8
3 files changed, 8 insertions, 7 deletions
diff --git a/src/wrapped/generated/functions_list.txt b/src/wrapped/generated/functions_list.txt
index bf306cfa..82b573e2 100644
--- a/src/wrapped/generated/functions_list.txt
+++ b/src/wrapped/generated/functions_list.txt
@@ -3506,6 +3506,7 @@
 #() iFEpuvvppp -> iFEpuppp
 wrappedalure:
 wrappedalut:
+wrappedandroidshmem:
 wrappedanl:
 wrappedatk:
 - vFp:
diff --git a/src/wrapped/wrappedgio2.c b/src/wrapped/wrappedgio2.c
index 45c650f1..47b92d63 100644
--- a/src/wrapped/wrappedgio2.c
+++ b/src/wrapped/wrappedgio2.c
@@ -356,11 +356,11 @@ static my_GDBusInterfaceVTable_t* findFreeGDBusInterfaceVTable(my_GDBusInterface
     #undef GO
     #define GO(A) if(ref_GDBusInterfaceVTable_##A == 0) {   \
         ref_GDBusInterfaceVTable_##A = fcts;                 \
-        my_GDBusInterfaceVTable_##A.method_call = (fcts->method_call)?((GetNativeFnc((uintptr_t)fcts->method_call))?GetNativeFnc((uintptr_t)fcts->method_call):my_funcs_method_call_##A):NULL;    \
+        my_GDBusInterfaceVTable_##A.method_call = (fcts->method_call)?((GetNativeFnc((uintptr_t)fcts->method_call))?GetNativeFnc((uintptr_t)fcts->method_call):(void*)my_funcs_method_call_##A):NULL;    \
         fct_funcs_method_call_##A = (uintptr_t)fcts->method_call;                            \
-        my_GDBusInterfaceVTable_##A.get_property = (fcts->get_property)?((GetNativeFnc((uintptr_t)fcts->get_property))?GetNativeFnc((uintptr_t)fcts->get_property):my_funcs_get_property_##A):NULL;    \
+        my_GDBusInterfaceVTable_##A.get_property = (fcts->get_property)?((GetNativeFnc((uintptr_t)fcts->get_property))?GetNativeFnc((uintptr_t)fcts->get_property):(void*)my_funcs_get_property_##A):NULL;    \
         fct_funcs_get_property_##A = (uintptr_t)fcts->get_property;                            \
-        my_GDBusInterfaceVTable_##A.set_property = (fcts->set_property)?((GetNativeFnc((uintptr_t)fcts->set_property))?GetNativeFnc((uintptr_t)fcts->set_property):my_funcs_set_property_##A):NULL;    \
+        my_GDBusInterfaceVTable_##A.set_property = (fcts->set_property)?((GetNativeFnc((uintptr_t)fcts->set_property))?GetNativeFnc((uintptr_t)fcts->set_property):(void*)my_funcs_set_property_##A):NULL;    \
         fct_funcs_set_property_##A = (uintptr_t)fcts->set_property;                            \
         return &my_GDBusInterfaceVTable_##A;                \
     }
diff --git a/src/wrapped/wrappedopenal.c b/src/wrapped/wrappedopenal.c
index fb478f33..c1fcd0a4 100644
--- a/src/wrapped/wrappedopenal.c
+++ b/src/wrapped/wrappedopenal.c
@@ -63,7 +63,7 @@ void my_alRequestFoldbackStop(x64emu_t* emu);
 
 #include "wrappedlib_init.h"
 
-void fillALProcWrapper()
+void fillALProcWrapper(box64context_t* context)
 {
     int cnt, ret;
     khint_t k;
@@ -82,7 +82,7 @@ void fillALProcWrapper()
         kh_value(symbolmap, k).w = openalmysymbolmap[i].w;
         kh_value(symbolmap, k).resolved = 0;
     }
-    my_context->alwrappers = symbolmap;
+    context->alwrappers = symbolmap;
     // fill my_* map
     symbolmap = kh_init(symbolmap);
     cnt = sizeof(MAPNAME(mysymbolmap))/sizeof(map_onesymbol_t);
@@ -91,7 +91,7 @@ void fillALProcWrapper()
         kh_value(symbolmap, k).w = openalmysymbolmap[i].w;
         kh_value(symbolmap, k).resolved = 0;
     }
-    my_context->almymap = symbolmap;
+    context->almymap = symbolmap;
 }
 void freeALProcWrapper(box64context_t* context)
 {
@@ -147,7 +147,7 @@ EXPORT void* my_alcGetProcAddress(x64emu_t* emu, void* device, void* name)
     const char* rname = (const char*)name;
     printf_log(LOG_DEBUG, "Calling alcGetProcAddress(%p, %s)\n", device, rname);
     if(!emu->context->alwrappers)   // could be moved in "my" structure...
-        fillALProcWrapper();
+        fillALProcWrapper(emu->context);
     // get proc adress using actual alGetProcAddress
     k = kh_get(symbolmap, emu->context->almymap, rname);
     int is_my = (k==kh_end(emu->context->almymap))?0:1;