~ubuntu-branches/ubuntu/natty/libvirt/natty-proposed

« back to all changes in this revision

Viewing changes to gnulib/lib/unistd.in.h

  • Committer: Bazaar Package Importer
  • Author(s): Laurent Léonard
  • Date: 2010-07-06 12:14:33 UTC
  • mto: (3.4.17 sid) (1.2.6 upstream) (0.3.1 upstream)
  • mto: This revision was merged to the branch mainline in revision 93.
  • Revision ID: james.westby@ubuntu.com-20100706121433-94utbax9zjvmkcsj
Tags: upstream-0.8.2
Import upstream version 0.8.2

Show diffs side-by-side

added added

removed removed

Lines of Context:
88
88
#endif
89
89
 
90
90
#if (@GNULIB_WRITE@ || @GNULIB_READLINK@ || @GNULIB_READLINKAT@ \
91
 
     || @GNULIB_PREAD@ || defined GNULIB_POSIXCHECK)
 
91
     || @GNULIB_PREAD@ || @GNULIB_PWRITE@ || defined GNULIB_POSIXCHECK)
92
92
/* Get ssize_t.  */
93
93
# include <sys/types.h>
94
94
#endif
1018
1018
#endif
1019
1019
 
1020
1020
 
 
1021
#if @GNULIB_PWRITE@
 
1022
/* Write at most BUFSIZE bytes from BUF into FD, starting at OFFSET.
 
1023
   Return the number of bytes written if successful, otherwise
 
1024
   set errno and return -1.  0 indicates nothing written.  See the
 
1025
   POSIX:2001 specification
 
1026
   <http://www.opengroup.org/susv3xsh/pwrite.html>.  */
 
1027
# if @REPLACE_PWRITE@
 
1028
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
 
1029
#   define pwrite rpl_pwrite
 
1030
#  endif
 
1031
_GL_FUNCDECL_RPL (pwrite, ssize_t,
 
1032
                  (int fd, const void *buf, size_t bufsize, off_t offset)
 
1033
                  _GL_ARG_NONNULL ((2)));
 
1034
_GL_CXXALIAS_RPL (pwrite, ssize_t,
 
1035
                  (int fd, const void *buf, size_t bufsize, off_t offset));
 
1036
# else
 
1037
#  if !@HAVE_PWRITE@
 
1038
_GL_FUNCDECL_SYS (pwrite, ssize_t,
 
1039
                  (int fd, const void *buf, size_t bufsize, off_t offset)
 
1040
                  _GL_ARG_NONNULL ((2)));
 
1041
#  endif
 
1042
_GL_CXXALIAS_SYS (pwrite, ssize_t,
 
1043
                  (int fd, const void *buf, size_t bufsize, off_t offset));
 
1044
# endif
 
1045
_GL_CXXALIASWARN (pwrite);
 
1046
#elif defined GNULIB_POSIXCHECK
 
1047
# undef pwrite
 
1048
# if HAVE_RAW_DECL_PWRITE
 
1049
_GL_WARN_ON_USE (pwrite, "pwrite is unportable - "
 
1050
                 "use gnulib module pwrite for portability");
 
1051
# endif
 
1052
#endif
 
1053
 
 
1054
 
1021
1055
#if @GNULIB_READLINK@
1022
1056
/* Read the contents of the symbolic link FILE and place the first BUFSIZE
1023
1057
   bytes of it into BUF.  Return the number of bytes placed into BUF if
1166
1200
#if @GNULIB_TTYNAME_R@
1167
1201
/* Store at most BUFLEN characters of the pathname of the terminal FD is
1168
1202
   open on in BUF.  Return 0 on success, otherwise an error number.  */
1169
 
# if !@HAVE_TTYNAME_R@
 
1203
# if @REPLACE_TTYNAME_R@
 
1204
#  if !(defined __cplusplus && defined GNULIB_NAMESPACE)
 
1205
#   undef ttyname_r
 
1206
#   define ttyname_r rpl_ttyname_r
 
1207
#  endif
 
1208
_GL_FUNCDECL_RPL (ttyname_r, int,
 
1209
                  (int fd, char *buf, size_t buflen) _GL_ARG_NONNULL ((2)));
 
1210
_GL_CXXALIAS_RPL (ttyname_r, int,
 
1211
                  (int fd, char *buf, size_t buflen));
 
1212
# else
 
1213
#  if !@HAVE_TTYNAME_R@
1170
1214
_GL_FUNCDECL_SYS (ttyname_r, int,
1171
1215
                  (int fd, char *buf, size_t buflen) _GL_ARG_NONNULL ((2)));
1172
 
# endif
 
1216
#  endif
1173
1217
_GL_CXXALIAS_SYS (ttyname_r, int,
1174
1218
                  (int fd, char *buf, size_t buflen));
 
1219
# endif
1175
1220
_GL_CXXALIASWARN (ttyname_r);
1176
1221
#elif defined GNULIB_POSIXCHECK
1177
1222
# undef ttyname_r