You've already forked Magisk
mirror of
https://github.com/topjohnwu/Magisk.git
synced 2025-09-06 06:36:58 +00:00
Fix segmentation fault
When both keepverity and keepforceencrypt are false, ‘e’ will be freed after removing ‘verity_key’ and segmentation fault might happened in strstr(e->filename, “fstab”) Signed-off-by: Shaka Huang <shakalaca@gmail.com>
This commit is contained in:
@@ -21,6 +21,7 @@ static void cpio_patch(struct vector *v, int keepverity, int keepforceencrypt) {
|
|||||||
fprintf(stderr, "Remove [verity_key]\n");
|
fprintf(stderr, "Remove [verity_key]\n");
|
||||||
cpio_free(e);
|
cpio_free(e);
|
||||||
vec_cur(v) = NULL;
|
vec_cur(v) = NULL;
|
||||||
|
continue;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (!keepforceencrypt) {
|
if (!keepforceencrypt) {
|
||||||
|
|||||||
Reference in New Issue
Block a user