[prev in list] [next in list] [prev in thread] [next in thread]
List: wine-devel
Subject: [PATCH] ntdll: fix backward compatibility for struct link_map on FreeBSD
From: Damjan Jovanovic <damjan.jov () gmail ! com>
Date: 2020-11-30 18:08:01
Message-ID: CAJm2B-nY0sq8y4MPgMOL=faRN4P=3DxSDi+iiEXC+VSJJCWqnw () mail ! gmail ! com
[Download RAW message or body]
Checking for the _rtld_version_laddr_offset symbol only works when
header and library versions match. Checking for the offset of l_addr
instead lets us use the older header with the new library too.
Signed-off-by: Damjan Jovanovic <damjan.jov@gmail.com>
---
dlls/ntdll/unix/loader.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
["0001-ntdll-fix-backward-compatibility-for-struct-link_map-o.txt" (text/plain)]
diff --git a/dlls/ntdll/unix/loader.c b/dlls/ntdll/unix/loader.c
index 61c8f5e18f5..f17b319b9ac 100644
--- a/dlls/ntdll/unix/loader.c
+++ b/dlls/ntdll/unix/loader.c
@@ -1417,7 +1417,7 @@ found:
#ifdef __FreeBSD__
/* On older FreeBSD versions, l_addr was the absolute load address, now it's \
the relocation offset. */
- if (!dlsym(RTLD_DEFAULT, "_rtld_version_laddr_offset"))
+ if (offsetof(struct link_map, l_addr) == 0)
if (!get_relocbase(map->l_addr, &relocbase)) return;
#endif
switch (dyn->d_tag)
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic