summaryrefslogtreecommitdiff
path: root/hurd/translator/procfs
diff options
context:
space:
mode:
Diffstat (limited to 'hurd/translator/procfs')
-rw-r--r--hurd/translator/procfs/jkoenig/discussion.mdwn25
1 files changed, 14 insertions, 11 deletions
diff --git a/hurd/translator/procfs/jkoenig/discussion.mdwn b/hurd/translator/procfs/jkoenig/discussion.mdwn
index 4cd4e5ca..d26f05f9 100644
--- a/hurd/translator/procfs/jkoenig/discussion.mdwn
+++ b/hurd/translator/procfs/jkoenig/discussion.mdwn
@@ -218,6 +218,20 @@ Needed by glibc's `pldd` tool (commit
[[!message-id "alpine.LFD.2.02.1110111111260.2016@akari"]]. Needed by glibc's
`stdlib/tst-secure-getenv.c`.
+Is it generally possible to use something like the following instead?
+Disadvantage is that every program using this needs to be patched.
+
+ #include <dlfcn.h>
+ [...]
+ Dl_info DLInfo;
+ int err = dladdr(&main, &DLInfo);
+ if (err == 0)
+ [...]
+ /* Pathname of shared object that contains address: DLInfo.dli_fname. */
+ /* Filter it through realpath. */
+
+This is used in `[LLVM]/lib/Support/Unix/Path.inc`.
+
# `/proc/[PID]/fd/`
@@ -300,17 +314,6 @@ Needed by glibc's `pldd` tool (commit
report why the test suite failed
-# IRC, freenode, #hurd, 2011-06-19
-
- <pinotree> jkoenig: procfs question: in process.c, process_lookup_pid, why
- is the entries[2].hook line repeated twice?
- <jkoenig> pinotree, let me check
- <jkoenig> pinotree, it's probably just a mistake, there's no way the second
- one has any effect
- <pinotree> jkoenig: i see, it looked like you c&p'd that code accidentally
- <jkoenig> pinotree, it's probably what happened, yes.
-
-
# `/proc/[PID]/cwd`
## IRC, freenode, #hurd, 2012-06-30