about summary refs log tree commit diff
path: root/sysdeps
diff options
context:
space:
mode:
authorUlrich Drepper <drepper@redhat.com>2004-02-22 19:37:31 +0000
committerUlrich Drepper <drepper@redhat.com>2004-02-22 19:37:31 +0000
commita8fd5a02d94dcbe9a75252a66d2d73b41b9a2c83 (patch)
tree25310d8d27f7cd221a2d7450d0b4d0e23b2791e7 /sysdeps
parentc91b8752c35d0d6b59419e3d39a7bd3dc1b45cc0 (diff)
downloadglibc-a8fd5a02d94dcbe9a75252a66d2d73b41b9a2c83.tar.gz
glibc-a8fd5a02d94dcbe9a75252a66d2d73b41b9a2c83.tar.xz
glibc-a8fd5a02d94dcbe9a75252a66d2d73b41b9a2c83.zip
Update.
2004-02-22  Ulrich Drepper  <drepper@redhat.com>

	* sysdeps/unix/sysv/linux/i386/posix_fadvise64.S: Pop register
	content also in case of an overflow in the parameter.
	Reported by Momchil Velikov <velco@fadata.bg>.
Diffstat (limited to 'sysdeps')
-rw-r--r--sysdeps/unix/sysv/linux/i386/posix_fadvise64.S8
1 files changed, 3 insertions, 5 deletions
diff --git a/sysdeps/unix/sysv/linux/i386/posix_fadvise64.S b/sysdeps/unix/sysv/linux/i386/posix_fadvise64.S
index 428ed2f9f8..b577f2284e 100644
--- a/sysdeps/unix/sysv/linux/i386/posix_fadvise64.S
+++ b/sysdeps/unix/sysv/linux/i386/posix_fadvise64.S
@@ -1,4 +1,4 @@
-/* Copyright (C) 1995,96,97,98,99,2000,2002,2003 Free Software Foundation, Inc.
+/* Copyright (C) 1995-2000,2002,2003,2004 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -85,6 +85,7 @@ ENTRY (BP_SYM (__posix_fadvise64_l64))
 
 	/* Overflow check.  */
 	cmpl	$0, LENHI(%esp)
+	movl	$-EOVERFLOW, %eax
 	jne	L(overflow)
 
 	movl	FD(%esp), %ebx
@@ -97,6 +98,7 @@ ENTRY (BP_SYM (__posix_fadvise64_l64))
 	ENTER_KERNEL
 
 	/* Restore registers.  */
+L(overflow):
 	popl	%edi
 	popl	%esi
 	popl	%ebx
@@ -106,10 +108,6 @@ ENTRY (BP_SYM (__posix_fadvise64_l64))
 
 	/* Successful; return the syscall's value.  */
 	ret
-
-L(overflow):
-	movl	$EOVERFLOW, %eax
-	ret
 #else
 	movl	$ENOSYS, %eax
 	ret