From 81e40a84009d602a4459a69cc99c9426aa4c6267 Mon Sep 17 00:00:00 2001 From: Liu Yuntao Date: Mon, 28 Aug 2023 21:26:49 +0800 Subject: [PATCH] fix bug when use_rto=0 --- src/binfmt_rto/binfmt_rto_604.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/binfmt_rto/binfmt_rto_604.c b/src/binfmt_rto/binfmt_rto_604.c index 44ad5a3..981e51c 100644 --- a/src/binfmt_rto/binfmt_rto_604.c +++ b/src/binfmt_rto/binfmt_rto_604.c @@ -1161,6 +1161,7 @@ static int load_elf_binary(struct linux_binprm *bprm) struct list_head *preload_seg_pos = NULL; struct loaded_seg *loaded_seg; + retval = -ENOEXEC; /* close feature to rmmod this ko */ if (!use_rto) { goto out; @@ -1170,7 +1171,6 @@ static int load_elf_binary(struct linux_binprm *bprm) load_rto: elf_ex = (struct elfhdr *)bprm->buf; is_rto_format = elf_ex->e_flags & OS_SPECIFIC_FLAG_RTO; - retval = -ENOEXEC; if (!is_rto_format && !is_rto_symbolic_link) { goto out; -- Gitee