mirror of
https://github.com/topjohnwu/Magisk.git
synced 2024-12-25 07:57:39 +00:00
Fix critical bug
This commit is contained in:
parent
4672a5fad6
commit
39a6bd33ce
@ -80,7 +80,7 @@ int cpio_commands(const char *command, int argc, char *argv[]) {
|
|||||||
parse_cpio(&v, incpio);
|
parse_cpio(&v, incpio);
|
||||||
|
|
||||||
if (strcmp(command, "test") == 0) {
|
if (strcmp(command, "test") == 0) {
|
||||||
return cpio_test(&v);
|
exit(cpio_test(&v));
|
||||||
} else if (strcmp(command, "restore") == 0) {
|
} else if (strcmp(command, "restore") == 0) {
|
||||||
ret = cpio_restore(&v);
|
ret = cpio_restore(&v);
|
||||||
} else if (strcmp(command, "stocksha1") == 0) {
|
} else if (strcmp(command, "stocksha1") == 0) {
|
||||||
|
@ -260,7 +260,7 @@ int getattrat(int dirfd, const char *pathname, struct file_attr *a) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
int fgetattr(int fd, struct file_attr *a) {
|
int fgetattr(int fd, struct file_attr *a) {
|
||||||
#ifndef NO_SELINUX
|
#ifdef SELINUX
|
||||||
char path[PATH_MAX];
|
char path[PATH_MAX];
|
||||||
fd_getpath(fd, path, sizeof(path));
|
fd_getpath(fd, path, sizeof(path));
|
||||||
return getattr(path, a);
|
return getattr(path, a);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user