aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/util/os_installation.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/util/os_installation.c b/src/util/os_installation.c
index c520c6f79..3e0efa0bf 100644
--- a/src/util/os_installation.c
+++ b/src/util/os_installation.c
@@ -101,6 +101,11 @@ get_path_from_proc_exe ()
101 lnk[size] = '\0'; 101 lnk[size] = '\0';
102 while ((lnk[size] != '/') && (size > 0)) 102 while ((lnk[size] != '/') && (size > 0))
103 size--; 103 size--;
104 /* test for being in lib/gnunet/libexec/ */
105 if ( (size > strlen ("/gnunet/libexec/")) &&
106 (0 == strcmp ("/gnunet/libexec/",
107 &lnk[size - strlen ("/gnunet/libexec/")])) )
108 size -= strlen ("gnunet/libexec/");
104 if ((size < 4) || (lnk[size - 4] != '/')) 109 if ((size < 4) || (lnk[size - 4] != '/'))
105 { 110 {
106 /* not installed in "/bin/" -- binary path probably useless */ 111 /* not installed in "/bin/" -- binary path probably useless */