summaryrefslogtreecommitdiffstats
path: root/debian/patches/fixes/Load-dependent-libraries-with-their-real-path.patch
blob: 088c79b0b8ece447ba4d15aa471e2f33bbb95a38 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
From: Christoph Goehre <chris@sigxcpu.org>
Date: Mon, 16 Sep 2013 20:40:57 +0200
Subject: Load dependent libraries with their real path

---
 xpcom/glue/standalone/nsXPCOMGlue.cpp | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/xpcom/glue/standalone/nsXPCOMGlue.cpp b/xpcom/glue/standalone/nsXPCOMGlue.cpp
index 09edef1..6930417 100644
--- a/xpcom/glue/standalone/nsXPCOMGlue.cpp
+++ b/xpcom/glue/standalone/nsXPCOMGlue.cpp
@@ -140,6 +140,9 @@ static ReadDependentCBResult ReadDependentCB(
     ReadAheadLib(aDependentLib);
   }
 #endif
+  char lib[MAXPATHLEN];
+  if (realpath(aDependentLib, lib))
+      aDependentLib = lib;
   LibHandleType libHandle;
   MOZ_TRY_VAR(libHandle, GetLibHandle(aDependentLib));