apr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From traw...@apache.org
Subject cvs commit: apr/include/arch/win32 fileio.h
Date Tue, 13 Feb 2001 18:48:53 GMT
trawick     01/02/13 10:48:53

  Modified:    .        configure.in
               file_io/unix dir.c
               include  apr.h.in apr.hw
               include/arch/win32 fileio.h
  Log:
  Define APR_PATH_MAX to solve a minor portability aggravation.  Win32
  APR already defined it privately for the Win32 implementation of APR.
  We now externalize it everywhere.
  
  Revision  Changes    Path
  1.225     +4 -2      apr/configure.in
  
  Index: configure.in
  ===================================================================
  RCS file: /home/cvs/apr/configure.in,v
  retrieving revision 1.224
  retrieving revision 1.225
  diff -u -r1.224 -r1.225
  --- configure.in	2001/02/11 00:39:54	1.224
  +++ configure.in	2001/02/13 18:48:47	1.225
  @@ -282,14 +282,14 @@
   AC_CHECK_HEADERS(fcntl.h, fcntlh="1", fcntl="0")
   AC_CHECK_HEADERS(grp.h)
   AC_CHECK_HEADERS(io.h, ioh="1", ioh="0")
  -AC_CHECK_HEADERS(limits.h)
  +AC_CHECK_HEADERS(limits.h, limitsh="1", limitsh="0")
   AC_CHECK_HEADERS(malloc.h)
   AC_CHECK_HEADERS(memory.h)
   AC_CHECK_HEADERS(netdb.h, netdbh="1", netdbh="0")
   AC_CHECK_HEADERS(osreldate.h)
   AC_CHECK_HEADERS(process.h)
   AC_CHECK_HEADERS(pwd.h)
  -AC_CHECK_HEADERS(sys/syslimits.h)
  +AC_CHECK_HEADERS(sys/syslimits.h, sys_syslimitsh="1", sys_syslimitsh="0")
   AC_CHECK_HEADERS(sys/sem.h)
   AC_CHECK_HEADERS(signal.h, signalh="1", signalh="0")
   AC_CHECK_HEADERS(stdarg.h, stdargh="1", stdargh="0")
  @@ -338,7 +338,9 @@
   AC_SUBST(direnth)
   AC_SUBST(fcntlh)
   AC_SUBST(ioh)
  +AC_SUBST(limitsh)
   AC_SUBST(netdbh)
  +AC_SUBST(sys_syslimitsh)
   AC_SUBST(netinet_inh)
   AC_SUBST(stdargh)
   AC_SUBST(stdioh)
  
  
  
  1.52      +1 -5      apr/file_io/unix/dir.c
  
  Index: dir.c
  ===================================================================
  RCS file: /home/cvs/apr/file_io/unix/dir.c,v
  retrieving revision 1.51
  retrieving revision 1.52
  diff -u -r1.51 -r1.52
  --- dir.c	2001/02/12 20:55:32	1.51
  +++ dir.c	2001/02/13 18:48:49	1.52
  @@ -154,11 +154,7 @@
       wanted &= ~(APR_FINFO_NAME);
       if (wanted)
       {
  -#if defined(PATH_MAX)
  -        char fspec[PATH_MAX];
  -#elif defined(_POSIX_PATH_MAX)
  -        char fspec[_POSIX_PATH_MAX];
  -#endif
  +        char fspec[APR_PATH_MAX];
           int off;
           apr_cpystrn(fspec, thedir->dirname, sizeof(fspec));
           off = strlen(fspec);
  
  
  
  1.66      +18 -0     apr/include/apr.h.in
  
  Index: apr.h.in
  ===================================================================
  RCS file: /home/cvs/apr/include/apr.h.in,v
  retrieving revision 1.65
  retrieving revision 1.66
  diff -u -r1.65 -r1.66
  --- apr.h.in	2001/02/11 00:39:55	1.65
  +++ apr.h.in	2001/02/13 18:48:51	1.66
  @@ -31,6 +31,7 @@
   #define APR_HAVE_ERRNO_H        @errnoh@
   #define APR_HAVE_FCNTL_H        @fcntlh@
   #define APR_HAVE_IO_H           @ioh@
  +#define APR_HAVE_LIMITS_H       @limitsh@
   #define APR_HAVE_NETDB_H        @netdbh@
   #define APR_HAVE_NETINET_IN_H   @netinet_inh@
   #define APR_HAVE_PTHREAD_H      @pthreadh@
  @@ -41,6 +42,7 @@
   #define APR_HAVE_STRINGS_H      @stringsh@
   #define APR_HAVE_SYS_SIGNAL_H   @sys_signalh@
   #define APR_HAVE_SYS_SOCKET_H   @sys_socketh@
  +#define APR_HAVE_SYS_SYSLIMITS_H @sys_syslimitsh@
   #define APR_HAVE_SYS_TYPES_H    @sys_typesh@
   #define APR_HAVE_SYS_UIO_H      @sys_uioh@
   #define APR_HAVE_SIGNAL_H       @signalh@
  @@ -233,6 +235,22 @@
   #define INCL_DOS
   #define INCL_DOSERRORS
   #include <os2.h>
  +#endif
  +
  +/* header files for PATH_MAX, _POSIX_PATH_MAX */
  +#if APR_HAVE_SYS_SYSLIMITS_H
  +#include <sys/syslimits.h>
  +#endif
  +#if APR_HAVE_LIMITS_H
  +#include <limits.h>
  +#endif
  +
  +#if defined(PATH_MAX)
  +#define APR_PATH_MAX       PATH_MAX
  +#elif defined(_POSIX_PATH_MAX)
  +#define APR_PATH_MAX       _POSIX_PATH_MAX
  +#else
  +#error no decision has been made on APR_PATH_MAX for your platform
   #endif
   
   #endif /* APR_H */
  
  
  
  1.52      +9 -0      apr/include/apr.hw
  
  Index: apr.hw
  ===================================================================
  RCS file: /home/cvs/apr/include/apr.hw,v
  retrieving revision 1.51
  retrieving revision 1.52
  diff -u -r1.51 -r1.52
  --- apr.hw	2001/02/11 20:34:53	1.51
  +++ apr.hw	2001/02/13 18:48:51	1.52
  @@ -121,6 +121,7 @@
   #define APR_HAVE_ERRNO_H        1
   #define APR_HAVE_FCNTL_H        1
   #define APR_HAVE_IO_H           1
  +#define APR_HAVE_LIMITS_H       0
   #define APR_HAVE_NETDB_H        0
   #define APR_HAVE_NETINET_IN_H   0
   #define APR_HAVE_PTHREAD_H      0
  @@ -131,6 +132,7 @@
   #define APR_HAVE_STRINGS_H      0
   #define APR_HAVE_SYS_SIGNAL_H   0
   #define APR_HAVE_SYS_SOCKET_H   0
  +#define APR_HAVE_SYS_SYSLIMITS_H 0
   #define APR_HAVE_SYS_TYPES_H    1
   #define APR_HAVE_SYS_UIO_H      0
   #define APR_HAVE_SIGNAL_H       1
  @@ -296,6 +298,13 @@
   #define STDIN_FILENO  0
   #define STDOUT_FILENO 1
   #define STDERR_FILENO 2
  +
  +#if APR_HAS_UNICODE_FS
  +/* An arbitrary size that is digestable. True max is a bit less than 32000 */
  +#define APR_PATH_MAX 8192
  +#else /* !APR_HAS_UNICODE_FS */
  +#define APR_PATH_MAX MAX_PATH
  +#endif
   
   #endif /* APR_H */
   #endif /* WIN32 */
  
  
  
  1.47      +0 -3      apr/include/arch/win32/fileio.h
  
  Index: fileio.h
  ===================================================================
  RCS file: /home/cvs/apr/include/arch/win32/fileio.h,v
  retrieving revision 1.46
  retrieving revision 1.47
  diff -u -r1.46 -r1.47
  --- fileio.h	2001/02/08 07:44:49	1.46
  +++ fileio.h	2001/02/13 18:48:52	1.47
  @@ -99,11 +99,8 @@
   apr_status_t unicode_to_utf8_path(char* dststr, apr_size_t dstchars, 
                                     const apr_wchar_t* srcstr);
   
  -/* An arbitrary size that is digestable. True max is a bit less than 32000 */
  -#define APR_PATH_MAX 8192
   #define APR_FILE_MAX MAX_PATH
   #else /* !APR_HAS_UNICODE_FS */
  -#define APR_PATH_MAX MAX_PATH
   #define APR_FILE_MAX MAX_PATH
   #endif
   
  
  
  

Mime
View raw message