diff options
author | Ulrich Drepper <drepper@redhat.com> | 2007-08-03 18:48:05 +0000 |
---|---|---|
committer | Ulrich Drepper <drepper@redhat.com> | 2007-08-03 18:48:05 +0000 |
commit | 2fb20667126f5fd79071860f572e763d5395d44a (patch) | |
tree | 7a6d8f1d1a8a661a505d2555f9f0d5f17a790b5c /rt/aio.h | |
parent | 64f6281cbb92c91989a51ca676eca245ea88228f (diff) | |
download | glibc-2fb20667126f5fd79071860f572e763d5395d44a.zip glibc-2fb20667126f5fd79071860f572e763d5395d44a.tar.gz glibc-2fb20667126f5fd79071860f572e763d5395d44a.tar.bz2 |
* rt/aio.h: Add __nonnull attributes.
Diffstat (limited to 'rt/aio.h')
-rw-r--r-- | rt/aio.h | 54 |
1 files changed, 31 insertions, 23 deletions
@@ -1,4 +1,4 @@ -/* Copyright (C) 1996-2000,2003,2004 Free Software Foundation, Inc. +/* Copyright (C) 1996-2000,2003,2004,2007 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 @@ -136,25 +136,26 @@ enum /* Allow user to specify optimization. */ #ifdef __USE_GNU -extern void aio_init (__const struct aioinit *__init) __THROW; +extern void aio_init (__const struct aioinit *__init) __THROW __nonnull ((1)); #endif #ifndef __USE_FILE_OFFSET64 /* Enqueue read request for given number of bytes and the given priority. */ -extern int aio_read (struct aiocb *__aiocbp) __THROW; +extern int aio_read (struct aiocb *__aiocbp) __THROW __nonnull ((1)); /* Enqueue write request for given number of bytes and the given priority. */ -extern int aio_write (struct aiocb *__aiocbp) __THROW; +extern int aio_write (struct aiocb *__aiocbp) __THROW __nonnull ((1)); /* Initiate list of I/O requests. */ extern int lio_listio (int __mode, struct aiocb *__const __list[__restrict_arr], - int __nent, struct sigevent *__restrict __sig) __THROW; + int __nent, struct sigevent *__restrict __sig) + __THROW __nonnull ((2)); /* Retrieve error status associated with AIOCBP. */ -extern int aio_error (__const struct aiocb *__aiocbp) __THROW; +extern int aio_error (__const struct aiocb *__aiocbp) __THROW __nonnull ((1)); /* Return status associated with AIOCBP. */ -extern __ssize_t aio_return (struct aiocb *__aiocbp) __THROW; +extern __ssize_t aio_return (struct aiocb *__aiocbp) __THROW __nonnull ((1)); /* Try to cancel asynchronous I/O requests outstanding against file descriptor FILDES. */ @@ -166,26 +167,30 @@ extern int aio_cancel (int __fildes, struct aiocb *__aiocbp) __THROW; This function is a cancellation point and therefore not marked with __THROW. */ extern int aio_suspend (__const struct aiocb *__const __list[], int __nent, - __const struct timespec *__restrict __timeout); + __const struct timespec *__restrict __timeout) + __nonnull ((1)); /* Force all operations associated with file desriptor described by `aio_fildes' member of AIOCBP. */ -extern int aio_fsync (int __operation, struct aiocb *__aiocbp) __THROW; +extern int aio_fsync (int __operation, struct aiocb *__aiocbp) + __THROW __nonnull ((2)); #else # ifdef __REDIRECT_NTH -extern int __REDIRECT_NTH (aio_read, (struct aiocb *__aiocbp), aio_read64); -extern int __REDIRECT_NTH (aio_write, (struct aiocb *__aiocbp), aio_write64); +extern int __REDIRECT_NTH (aio_read, (struct aiocb *__aiocbp), aio_read64) + __nonnull ((1)); +extern int __REDIRECT_NTH (aio_write, (struct aiocb *__aiocbp), aio_write64) + __nonnull ((1)); extern int __REDIRECT_NTH (lio_listio, (int __mode, struct aiocb *__const __list[__restrict_arr], int __nent, struct sigevent *__restrict __sig), - lio_listio64); + lio_listio64) __nonnull ((2)); extern int __REDIRECT_NTH (aio_error, (__const struct aiocb *__aiocbp), - aio_error64); + aio_error64) __nonnull ((1)); extern __ssize_t __REDIRECT_NTH (aio_return, (struct aiocb *__aiocbp), - aio_return64); + aio_return64) __nonnull ((1)); extern int __REDIRECT_NTH (aio_cancel, (int __fildes, struct aiocb *__aiocbp), @@ -194,11 +199,11 @@ extern int __REDIRECT_NTH (aio_cancel, extern int __REDIRECT_NTH (aio_suspend, (__const struct aiocb *__const __list[], int __nent, __const struct timespec *__restrict __timeout), - aio_suspend64); + aio_suspend64) __nonnull ((1)); extern int __REDIRECT_NTH (aio_fsync, (int __operation, struct aiocb *__aiocbp), - aio_fsync64); + aio_fsync64) __nonnull ((2)); # else # define aio_read aio_read64 @@ -213,24 +218,27 @@ extern int __REDIRECT_NTH (aio_fsync, #endif #ifdef __USE_LARGEFILE64 -extern int aio_read64 (struct aiocb64 *__aiocbp) __THROW; -extern int aio_write64 (struct aiocb64 *__aiocbp) __THROW; +extern int aio_read64 (struct aiocb64 *__aiocbp) __THROW __nonnull ((1)); +extern int aio_write64 (struct aiocb64 *__aiocbp) __THROW __nonnull ((1)); extern int lio_listio64 (int __mode, struct aiocb64 *__const __list[__restrict_arr], int __nent, struct sigevent *__restrict __sig) - __THROW; + __THROW __nonnull ((2)); -extern int aio_error64 (__const struct aiocb64 *__aiocbp) __THROW; -extern __ssize_t aio_return64 (struct aiocb64 *__aiocbp) __THROW; +extern int aio_error64 (__const struct aiocb64 *__aiocbp) + __THROW __nonnull ((1)); +extern __ssize_t aio_return64 (struct aiocb64 *__aiocbp) + __THROW __nonnull ((1)); extern int aio_cancel64 (int __fildes, struct aiocb64 *__aiocbp) __THROW; extern int aio_suspend64 (__const struct aiocb64 *__const __list[], int __nent, __const struct timespec *__restrict __timeout) - __THROW; + __THROW __nonnull ((1)); -extern int aio_fsync64 (int __operation, struct aiocb64 *__aiocbp) __THROW; +extern int aio_fsync64 (int __operation, struct aiocb64 *__aiocbp) + __THROW __nonnull ((2)); #endif __END_DECLS |