diff options
Diffstat (limited to 'sysdeps')
-rw-r--r-- | sysdeps/unix/sysv/linux/x86_64/sysdep.h | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/sysdeps/unix/sysv/linux/x86_64/sysdep.h b/sysdeps/unix/sysv/linux/x86_64/sysdep.h index adccc50bba..2da4d41fac 100644 --- a/sysdeps/unix/sysv/linux/x86_64/sysdep.h +++ b/sysdeps/unix/sysv/linux/x86_64/sysdep.h @@ -93,9 +93,14 @@ orq $-1, %rax; \ jmp L(pseudo_end); #elif USE___THREAD +# ifndef NOT_IN_libc +# define SYSCALL_ERROR_ERRNO __libc_errno +# else +# define SYSCALL_ERROR_ERRNO errno +# endif # define SYSCALL_ERROR_HANDLER \ 0: \ - movq __libc_errno@GOTTPOFF(%rip), %rcx; \ + movq SYSCALL_ERROR_ERRNO@GOTTPOFF(%rip), %rcx;\ xorq %rdx, %rdx; \ subq %rax, %rdx; \ movl %edx, %fs:(%rcx); \ |