mirror of
https://github.com/topjohnwu/Magisk.git
synced 2024-12-24 19:08:26 +00:00
Fix nullptr dereference when env abnormal
This commit is contained in:
parent
50710c72ad
commit
49abfcafed
@ -574,6 +574,7 @@ void magic_mount() {
|
||||
|
||||
char buf[4096];
|
||||
LOGI("* Loading modules\n");
|
||||
if (modules) {
|
||||
for (const auto &m : *modules) {
|
||||
const char *module = m.name.data();
|
||||
char *b = buf + sprintf(buf, "%s/" MODULEMNT "/%s/", MAGISKTMP.data(), module);
|
||||
@ -601,7 +602,7 @@ void magic_mount() {
|
||||
system->collect_files(module, fd);
|
||||
close(fd);
|
||||
}
|
||||
|
||||
}
|
||||
if (MAGISKTMP != "/sbin") {
|
||||
// Need to inject our binaries into /system/bin
|
||||
inject_magisk_bins(system);
|
||||
|
Loading…
x
Reference in New Issue
Block a user