Skip to content

Commit 187fb89

Browse files
committed
main: Conditionally enable Linux specfic syscall handle
Signed-off-by: Akira Moroo <[email protected]>
1 parent afa47a4 commit 187fb89

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

main.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -138,6 +138,7 @@ void ____asm_impl(void) {
138138
".globl asm_syscall_hook \n\t"
139139
"asm_syscall_hook: \n\t"
140140

141+
#if defined(__linux__)
141142
"cmp x8, #139 \n\t" /* rt_sigreturn */
142143
"b.eq do_rt_sigreturn \n\t" /* bypass hook */
143144
"cmp x8, #220 \n\t" /* clone */
@@ -179,6 +180,7 @@ void ____asm_impl(void) {
179180
/* Copy x0-x30 to cl_args->stack + cl_args->stack_size */
180181
SAVE_CONTEXT(x15)
181182
"b do_syscall_hook \n\t"
183+
#endif /* defined(__linux__) */
182184

183185
"do_syscall_hook: \n\t"
184186

0 commit comments

Comments
 (0)