I: [PATCH] sendfile() and sendfile64() wrongly have __nonnull((3)) declaration

Dmitry V. Levin ldv@altlinux.org
Sun May 22 23:19:00 GMT 2005


Hi,

In io/sys/sendfile.h, declarations of sendfile() and sendfile64() have
	__THROW __nonnull ((3))
However, in the comment few lines above the sendfile() declaration you can
read: "If OFFSET is a null pointer, use the normal file position instead."
Therefore this __nonnul declaration appears to be incorrect and should
be removed.


-- 
ldv
-------------- next part --------------
2005-05-22  Dmitry V. Levin  <ldv@altlinux.org>

	[BZ #961]
	* io/sys/sendfile.h: Remove __nonnull from sendfile and sendfile64
	declarations.

diff -u -p -r1.4 sendfile.h
--- io/sys/sendfile.h	17 Sep 2004 08:22:21 -0000	1.4
+++ io/sys/sendfile.h	22 May 2005 22:10:22 -0000
@@ -32,19 +32,19 @@ __BEGIN_DECLS
    case of error.  */
 #ifndef __USE_FILE_OFFSET64
 extern ssize_t sendfile (int __out_fd, int __in_fd, off_t *__offset,
-			 size_t __count) __THROW __nonnull ((3));
+			 size_t __count) __THROW;
 #else
 # ifdef __REDIRECT_NTH
 extern ssize_t __REDIRECT_NTH (sendfile,
 			       (int __out_fd, int __in_fd, __off64_t *__offset,
-				size_t __count), sendfile64) __nonnull ((3));
+				size_t __count), sendfile64);
 # else
 #  define sendfile sendfile64
 # endif
 #endif
 #ifdef __USE_LARGEFILE64
 extern ssize_t sendfile64 (int __out_fd, int __in_fd, __off64_t *__offset,
-			   size_t __count) __THROW __nonnull ((3));
+			   size_t __count) __THROW;
 #endif
 
 __END_DECLS
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://sourceware.org/pipermail/libc-alpha/attachments/20050522/ceb2a247/attachment.sig>


More information about the Libc-alpha mailing list