Properly detect SysUI appId

Fix #6322
This commit is contained in:
topjohnwu
2022-11-01 02:04:50 -07:00
parent 44643ad7b3
commit cf9957ce4d
3 changed files with 9 additions and 6 deletions

View File

@@ -126,7 +126,7 @@ static bool magisk_env() {
string pkg;
get_manager(0, &pkg);
sprintf(buf, "%s/0/%s/install", APP_DATA_DIR,
ssprintf(buf, sizeof(buf), "%s/0/%s/install", APP_DATA_DIR,
pkg.empty() ? "xxx" /* Ensure non-exist path */ : pkg.data());
// Alternative binaries paths