From 77da24ab589da17d343c3cebc274c9fa6da3cfd6 Mon Sep 17 00:00:00 2001 From: engstk Date: Thu, 25 Jul 2024 10:04:43 +0100 Subject: [PATCH] drivers: kernelsu: update to v1.0.1 also set gitversion to 1728 Signed-off-by: engstk --- drivers/kernelsu/Makefile | 2 +- drivers/kernelsu/selinux/selinux.c | 4 ++-- drivers/kernelsu/throne_tracker.c | 4 ++-- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/drivers/kernelsu/Makefile b/drivers/kernelsu/Makefile index 4d4fbd6bd..878c54c61 100644 --- a/drivers/kernelsu/Makefile +++ b/drivers/kernelsu/Makefile @@ -20,7 +20,7 @@ obj-$(CONFIG_KSU) += kernelsu.o # ifeq ($(shell test -e $(srctree)/$(src)/../.git; echo $$?),0) # $(shell cd $(srctree)/$(src); /usr/bin/env PATH="$$PATH":/usr/bin:/usr/local/bin [ -f ../.git/shallow ] && git fetch --unshallow) # KSU_GIT_VERSION := $(shell cd $(srctree)/$(src); /usr/bin/env PATH="$$PATH":/usr/bin:/usr/local/bin git rev-list --count HEAD) -KSU_GIT_VERSION := 1674 +KSU_GIT_VERSION := 1728 # ksu_version: major * 10000 + git version + 200 for historical reasons $(eval KSU_VERSION=$(shell expr 10000 + $(KSU_GIT_VERSION) + 200)) $(info -- KernelSU version: $(KSU_VERSION)) diff --git a/drivers/kernelsu/selinux/selinux.c b/drivers/kernelsu/selinux/selinux.c index 740953620..17a25dae5 100644 --- a/drivers/kernelsu/selinux/selinux.c +++ b/drivers/kernelsu/selinux/selinux.c @@ -116,7 +116,7 @@ bool is_zygote(void *sec) return result; } -#define DEVPTS_DOMAIN "u:object_r:devpts:s0" +#define DEVPTS_DOMAIN "u:object_r:ksu_file:s0" u32 ksu_get_devpts_sid() { @@ -127,4 +127,4 @@ u32 ksu_get_devpts_sid() pr_info("get devpts sid err %d\n", err); } return devpts_sid; -} \ No newline at end of file +} diff --git a/drivers/kernelsu/throne_tracker.c b/drivers/kernelsu/throne_tracker.c index eb04c8b0f..d7c1dae14 100644 --- a/drivers/kernelsu/throne_tracker.c +++ b/drivers/kernelsu/throne_tracker.c @@ -236,13 +236,13 @@ void search_manager(const char *path, int depth, struct list_head *uid_data) file = ksu_filp_open_compat(pos->dirpath, O_RDONLY | O_NOFOLLOW, 0); if (IS_ERR(file)) { pr_err("Failed to open directory: %s, err: %ld\n", pos->dirpath, PTR_ERR(file)); - return; + goto skip_iterate; } iterate_dir(file, &ctx.ctx); filp_close(file, NULL); } - +skip_iterate: list_del(&pos->list); if (pos != &data) kfree(pos);