termux-packages/x11-packages/i3/i3-4.15_libi3_get_exe_path.c.patch
2022-04-18 14:08:05 +05:30

25 lines
939 B
Diff
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

diff -uNr i3-4.15/libi3/get_exe_path.c i3-4.15.mod/libi3/get_exe_path.c
--- i3-4.15/libi3/get_exe_path.c 2018-03-10 19:29:14.000000000 +0200
+++ i3-4.15.mod/libi3/get_exe_path.c 2018-06-21 22:17:26.293653511 +0300
@@ -73,12 +73,7 @@
/* Fall back to searching $PATH (or _CS_PATH in absence of $PATH). */
char *path = getenv("PATH");
if (path == NULL) {
- /* _CS_PATH is typically something like "/bin:/usr/bin" */
- while (confstr(_CS_PATH, tmp, tmp_size) > tmp_size) {
- tmp_size = tmp_size * 2;
- tmp = srealloc(tmp, tmp_size);
- }
- sasprintf(&path, ":%s", tmp);
+ path = sstrdup("@TERMUX_PREFIX@/bin:@TERMUX_PREFIX@/bin/applets");
} else {
path = sstrdup(path);
}
@@ -103,5 +98,5 @@
free(tmp);
/* Last resort: maybe its in /usr/bin? */
- return sstrdup("/usr/bin/i3-nagbar");
+ return sstrdup("@TERMUX_PREFIX@/bin/i3-nagbar");
}