about summary refs log tree commit diff stats
path: root/src/wrapped/wrappedldlinux.c
diff options
context:
space:
mode:
authorptitSeb <sebastien.chev@gmail.com>2021-07-04 22:58:06 +0200
committerptitSeb <sebastien.chev@gmail.com>2021-07-04 22:58:06 +0200
commit27b3a3f33c90fc0daaf0ca8708c806b2a71b1625 (patch)
tree8e6198379d7b86fb7b40175e8fe7e086d7b2e6ae /src/wrapped/wrappedldlinux.c
parentd60a0ef58d8fc23c29cb783232a2915f48c9bf4a (diff)
downloadbox64-27b3a3f33c90fc0daaf0ca8708c806b2a71b1625.tar.gz
box64-27b3a3f33c90fc0daaf0ca8708c806b2a71b1625.zip
Improved TLS handling (for #17, but probably help many other programs)
Diffstat (limited to 'src/wrapped/wrappedldlinux.c')
-rwxr-xr-xsrc/wrapped/wrappedldlinux.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/wrapped/wrappedldlinux.c b/src/wrapped/wrappedldlinux.c
index eaea93d8..e8c56bc0 100755
--- a/src/wrapped/wrappedldlinux.c
+++ b/src/wrapped/wrappedldlinux.c
@@ -23,7 +23,8 @@ typedef struct my_tls_s {
 EXPORT void* my___tls_get_addr(x64emu_t* emu, void* p)
 {
     my_tls_t *t = (my_tls_t*)p;
-    return GetDTatOffset(emu->context, t->i, t->o);
+    void* ret = GetDTatOffset(emu->context, t->i, t->o);
+    return ret;
 }
 
 // don't try to load the actual ld-linux (because name is variable), just use box64 itself, as it's linked to ld-linux