Thunks: Convert guest thunk to asm, to avoid issues with older gcc verions

This commit is contained in:
Stefanos Kornilios Mitsis Poiitidis committed 2021-02-26 12:43:37 +02:00
1 parent 2071bab238
commit 70a98cd465
1 file changed
+1 -1
+1 -1
View File
@@ -1,7 +1,7 @@
#pragma once
#include <stdint.h>
#define MAKE_THUNK(lib, name, hash) static __attribute__((naked)) int fexthunks_##lib##_##name(void *args) { asm(".byte 0xF, 0x3F"); asm(".byte " hash ); }
#define MAKE_THUNK(lib, name, hash) extern "C" { int fexthunks_##lib##_##name(void *args); } asm("fexthunks_" #lib "_" #name ":\n.byte 0xF, 0x3F\n.byte " hash );
struct LoadlibArgs {
const char *Name;