apr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From field...@apache.org
Subject cvs commit: apr/network_io/unix sendrecv.c
Date Tue, 01 Apr 2003 20:13:29 GMT
fielding    2003/04/01 12:13:29

  Modified:    network_io/unix sendrecv.c
  Log:
  Make consistent with other platforms by not exporting apr_sendfile
  if no APR_HAS_SENDFILE.  If it should be exported, then someone will
  have to remove the conditionals from the global include file and
  add stubs to the other platforms for apr_sendfile and apr_socket_sendfile.
  
  Revision  Changes    Path
  1.96      +7 -24     apr/network_io/unix/sendrecv.c
  
  Index: sendrecv.c
  ===================================================================
  RCS file: /home/cvs/apr/network_io/unix/sendrecv.c,v
  retrieving revision 1.95
  retrieving revision 1.96
  diff -u -r1.95 -r1.96
  --- sendrecv.c	7 Jan 2003 00:52:56 -0000	1.95
  +++ sendrecv.c	1 Apr 2003 20:13:29 -0000	1.96
  @@ -994,25 +994,16 @@
   #error version of it for APR yet.  To get past this, either write apr_sendfile
   #error or change APR_HAS_SENDFILE in apr.h to 0. 
   #endif /* __linux__, __FreeBSD__, __HPUX__, _AIX, __MVS__, Tru64/OSF1 */
  -#endif /* APR_HAS_SENDFILE */
   
  -#if !APR_HAS_SENDFILE
  -/* currently, exports.c includes a reference to apr_sendfile() even if 
  - * apr_sendfile() doesn't work on the platform;
  - * this dummy version is just to get exports.c to compile/link
  - */
  -apr_status_t apr_socket_sendfile(apr_socket_t *sock, apr_file_t *file,
  -                                 apr_hdtr_t *hdtr, apr_off_t *offset,
  -                                 apr_size_t *len, apr_int32_t flags); 
  -                                 /* avoid warning for no proto */
  -
  -apr_status_t apr_socket_sendfile(apr_socket_t *sock, apr_file_t *file,
  -                                 apr_hdtr_t *hdtr, apr_off_t *offset,
  -                                 apr_size_t *len, apr_int32_t flags)
  +/* deprecated */
  +apr_status_t apr_sendfile(apr_socket_t *sock, apr_file_t *file,
  +                          apr_hdtr_t *hdtr, apr_off_t *offset, apr_size_t *len,
  +                          apr_int32_t flags)
   {
  -    return APR_ENOTIMPL;
  +    return apr_socket_sendfile(sock, file, hdtr, offset, len, flags);
   }
  -#endif
  +
  +#endif /* APR_HAS_SENDFILE */
   
   /* deprecated */
   apr_status_t apr_send(apr_socket_t *sock, const char *buf, apr_size_t *len)
  @@ -1042,14 +1033,6 @@
                             apr_size_t *len)
   {
       return apr_socket_recvfrom(from, sock, flags, buf, len);
  -}
  -
  -/* deprecated */
  -apr_status_t apr_sendfile(apr_socket_t *sock, apr_file_t *file,
  -                          apr_hdtr_t *hdtr, apr_off_t *offset, apr_size_t *len,
  -                          apr_int32_t flags)
  -{
  -    return apr_socket_sendfile(sock, file, hdtr, offset, len, flags);
   }
   
   /* deprecated */
  
  
  

Mime
View raw message