mirror of
https://github.com/topjohnwu/Magisk.git
synced 2024-11-23 18:15:30 +00:00
Apparently, not every device uses emmc
This commit is contained in:
parent
541ba357bb
commit
8bf382adad
@ -191,7 +191,10 @@ void unlock_blocks() {
|
||||
return;
|
||||
|
||||
while((entry = readdir(dir))) {
|
||||
if (entry->d_type == DT_BLK && strstr(entry->d_name, "mmc") != NULL) {
|
||||
if (entry->d_type == DT_BLK &&
|
||||
strstr(entry->d_name, "ram") == NULL &&
|
||||
strstr(entry->d_name, "loop") == NULL &&
|
||||
strstr(entry->d_name, "dm-0") == NULL) {
|
||||
snprintf(path, sizeof(path), "%s/%s", DEV_BLOCK, entry->d_name);
|
||||
if ((fd = xopen(path, O_RDONLY)) < 0)
|
||||
continue;
|
||||
|
Loading…
Reference in New Issue
Block a user