mirror of
https://github.com/topjohnwu/Magisk.git
synced 2025-12-27 13:13:15 -08:00
Remove usage of MAGISKTMP
This commit is contained in:
@@ -15,15 +15,17 @@ using namespace std;
|
||||
|
||||
static const char *bbpath() {
|
||||
static string path;
|
||||
if (path.empty())
|
||||
path = MAGISKTMP + "/" BBPATH "/busybox";
|
||||
if (path.empty()) {
|
||||
path = get_magisk_tmp();
|
||||
path += "/" BBPATH "/busybox";
|
||||
}
|
||||
return path.data();
|
||||
}
|
||||
|
||||
static void set_script_env() {
|
||||
setenv("ASH_STANDALONE", "1", 1);
|
||||
char new_path[4096];
|
||||
sprintf(new_path, "%s:%s", getenv("PATH"), MAGISKTMP.data());
|
||||
ssprintf(new_path, sizeof(new_path), "%s:%s", getenv("PATH"), get_magisk_tmp());
|
||||
setenv("PATH", new_path, 1);
|
||||
if (zygisk_enabled)
|
||||
setenv("ZYGISK_ENABLED", "1", 1);
|
||||
|
||||
Reference in New Issue
Block a user