kernel: fix potential dead loop

Co-Authored-by: qwerty472123
This commit is contained in:
weishu
2024-03-30 16:13:08 +08:00
parent 942866d986
commit 4a73672190

View File

@@ -229,7 +229,8 @@ static __always_inline bool check_v2_signature(char *path,
goto clean; goto clean;
} }
for (;;) { int loop_count = 0;
while (loop_count++ < 10) {
uint32_t id; uint32_t id;
uint32_t offset; uint32_t offset;
ksu_kernel_read_compat(fp, &size8, 0x8, ksu_kernel_read_compat(fp, &size8, 0x8,