Просмотр исходного кода

jump straight to __syscall_error

Mike Frysinger 19 лет назад
Родитель
Сommit
71f8450fce

+ 5 - 8
libc/sysdeps/linux/i386/clone.S

@@ -51,19 +51,19 @@ __clone:
 	/* no NULL function pointers */
 	movl	FUNC(%esp),%ecx
 #ifdef __PIC__
-	jecxz	__error
+	jecxz	__syscall_error
 #else
 	testl	%ecx,%ecx
-	jz	__error
+	jz	__syscall_error
 #endif
 
 	/* no NULL stack pointers */
 	movl	STACK(%esp),%ecx
 #ifdef __PIC__
-	jecxz	__error
+	jecxz	__syscall_error
 #else
 	testl	%ecx,%ecx
-	jz	__error
+	jz	__syscall_error
 #endif
 
 	/* Insert the argument onto the new stack.  Make sure the new
@@ -96,7 +96,7 @@ __clone:
 	popl	%ebx
 
 	test	%eax,%eax
-	jl	__error
+	jl	__syscall_error
 	jz	.Lthread_start
 	ret
 
@@ -114,9 +114,6 @@ __clone:
 	movl	$__NR_exit, %eax
 	int	$0x80
 
-__error:
-	jmp	__syscall_error
-
 .size __clone,.-__clone
 
 .weak clone

+ 1 - 4
libc/sysdeps/linux/i386/mmap64.S

@@ -76,7 +76,7 @@ mmap64:
 
 	/* If 0 > %eax > -4096 there was an error.  */
 	cmpl $-4095,%eax
-	ja __error
+	ja __syscall_error
 	/* Successful; return the syscall's value.  */
 	ret
 
@@ -89,9 +89,6 @@ L_einval:
 	movl $-EINVAL, %eax
 	jmp __error
 
-__error:
-	jmp	__syscall_error
-
 .size mmap64,.-mmap64
 
 #endif

+ 1 - 4
libc/sysdeps/linux/i386/syscall.S

@@ -45,10 +45,7 @@ syscall:
 	popl %ebp
 
 	cmpl $-4095,%eax
-	jae  __error
+	jae  __syscall_error
 	ret			/* Return to caller.  */
 
-__error:
-	jmp	__syscall_error
-
 .size syscall,.-syscall

+ 1 - 4
libc/sysdeps/linux/i386/vfork.S

@@ -23,12 +23,9 @@ __vfork:
 	int $0x80
 	pushl %ecx
 	cmpl $-4095,%eax
-	jae __error
+	jae __syscall_error
 	ret
 
-__error:
-	jmp	__syscall_error
-
 .size __vfork,.-__vfork