From: Ulrich Drepper Date: Sun, 16 Jan 2000 04:52:59 +0000 (+0000) Subject: Fix code generated if mmap2 is available when compiling but no at X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b59c6665c3d3c46c7bcc7699f7cc2349e3748354;p=thirdparty%2Fglibc.git Fix code generated if mmap2 is available when compiling but no at runtime. --- diff --git a/sysdeps/unix/sysv/linux/i386/mmap64.S b/sysdeps/unix/sysv/linux/i386/mmap64.S index 6d7dfe40224..9a355893987 100644 --- a/sysdeps/unix/sysv/linux/i386/mmap64.S +++ b/sysdeps/unix/sysv/linux/i386/mmap64.S @@ -91,16 +91,12 @@ L(einval): movl %ebx, %edx cmpl $0, 28(%esp) - jne L(einval) + jne L(einval2) movl $SYS_ify(mmap), %eax /* System call number in %eax. */ lea 4(%esp), %ebx /* Address of args is 1st arg. */ -# ifdef __NR_mmap2 - jmp L(do_syscall) -# else - /* Do the system call trap. */ int $0x80 @@ -112,14 +108,15 @@ L(einval): ja SYSCALL_ERROR_LABEL /* Successful; return the syscall's value. */ +#ifndef __NR_mmap2 L(pseudo_end): +#endif ret -L(einval): +L(einval2): movl %edx, %ebx movl $-EINVAL, %eax jmp SYSCALL_ERROR_LABEL -# endif #endif PSEUDO_END (__mmap64)