apr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bnicho...@apache.org
Subject cvs commit: apr/include/arch/netware internal_time.h apr_private.h
Date Fri, 08 Feb 2002 19:13:43 GMT
bnicholes    02/02/08 11:13:43

  Modified:    misc/netware rand.c aprlib.def
               file_io/netware pipe.c
               include/arch/netware internal_time.h apr_private.h
  Log:
  Getting ready for some API name changes in the NetWare libraries
  
  Revision  Changes    Path
  1.2       +9 -0      apr/misc/netware/rand.c
  
  Index: rand.c
  ===================================================================
  RCS file: /home/cvs/apr/misc/netware/rand.c,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- rand.c	28 Jan 2002 23:40:59 -0000	1.1
  +++ rand.c	8 Feb 2002 19:13:43 -0000	1.2
  @@ -55,15 +55,24 @@
   #define APR_WANT_MEMFUNC
   #include "apr_want.h"
   #include "apr_general.h"
  +#include "apr_private.h"
   
   #if APR_HAS_RANDOM
   
   #include <nks/plat.h>
   
  +#ifdef WAITING_FOR_UPDATE
  +int          NXGetRandom( size_t width, void *result );
  +#endif
  +
   APR_DECLARE(apr_status_t) apr_generate_random_bytes(unsigned char *buf, 
                                                       int length) 
   {
  +#ifdef WAITING_FOR_UPDATE
       return NXGetRandom(length, buf);
  +#else
  +    return NXSeedRandom(length, buf);
  +#endif
   }
   
   #endif /* APR_HAS_RANDOM */
  
  
  
  1.4       +3 -0      apr/misc/netware/aprlib.def
  
  Index: aprlib.def
  ===================================================================
  RCS file: /home/cvs/apr/misc/netware/aprlib.def,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- aprlib.def	2 Nov 2001 18:22:35 -0000	1.3
  +++ aprlib.def	8 Feb 2002 19:13:43 -0000	1.4
  @@ -1,3 +1,6 @@
   MODULE  LIBC.NLM
   MODULE  WS2_32.NLM
  +IMPORT  NXGetRandom
  +IMPORT  NXGetCtlInfo
  +IMPORT  NXSetCtlInfo
   EXPORT	@aprlib.imp
  
  
  
  1.4       +17 -0     apr/file_io/netware/pipe.c
  
  Index: pipe.c
  ===================================================================
  RCS file: /home/cvs/apr/file_io/netware/pipe.c,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- pipe.c	29 Jan 2002 00:38:26 -0000	1.3
  +++ pipe.c	8 Feb 2002 19:13:43 -0000	1.4
  @@ -54,6 +54,7 @@
   
   #include <stdio.h>
   #include <nks/fsio.h>
  +#include <nks/errno.h>
   
   #include "fileio.h"
   #include "apr_strings.h"
  @@ -92,9 +93,18 @@
       return rv;
   }
   
  +#ifdef WAITING_FOR_UPDATE
  +#ifndef NX_CTL_FLAGS
  +#define NX_CTL_FLAGS             0x00000001
  +int   NXGetCtlInfo(NXHandle_t handle, unsigned long command, ...);
  +int   NXSetCtlInfo(NXHandle_t handle, unsigned long command, ...);
  +#endif
  +#endif
  +
   static apr_status_t pipeblock(apr_file_t *thepipe)
   {
   	int				err;
  +#ifdef WAITING_FOR_UPDATE
   	unsigned long	flags;
   
   	if (!(err = NXGetCtlInfo(thepipe->filedes, NX_CTL_FLAGS, &flags)))
  @@ -102,6 +112,9 @@
   		flags &= ~NX_O_NONBLOCK;
   		err    = NXSetCtlInfo(thepipe->filedes, NX_CTL_FLAGS, flags);
   	}
  +#else
  +    err = NXIoSetBlockingState(thepipe->filedes, 1);
  +#endif
   
       if (err)
           return convert_error (err);
  @@ -113,6 +126,7 @@
   static apr_status_t pipenonblock(apr_file_t *thepipe)
   {
   	int				err;
  +#ifdef WAITING_FOR_UPDATE
   	unsigned long	flags;
   
   	if (!(err = NXGetCtlInfo(thepipe->filedes, NX_CTL_FLAGS, &flags)))
  @@ -120,6 +134,9 @@
   		flags |= NX_O_NONBLOCK;
   		err    = NXSetCtlInfo(thepipe->filedes, NX_CTL_FLAGS, flags);
   	}
  +#else
  +    err = NXIoSetBlockingState(thepipe->filedes, 0);
  +#endif
   
       if (err)
           return convert_error (err);
  
  
  
  1.2       +5 -0      apr/include/arch/netware/internal_time.h
  
  Index: internal_time.h
  ===================================================================
  RCS file: /home/cvs/apr/include/arch/netware/internal_time.h,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- internal_time.h	5 Nov 2001 19:59:28 -0000	1.1
  +++ internal_time.h	8 Feb 2002 19:13:43 -0000	1.2
  @@ -57,6 +57,11 @@
   
   #include "apr.h"
   
  +#ifdef WAITING_FOR_UPDATE
  +#undef timezone
  +# define timezone           (*___timezone())
  +#endif
  +
   void apr_netware_setup_time(void);
   
   #endif  /* TIME_INTERNAL_H */
  
  
  
  1.6       +3 -0      apr/include/arch/netware/apr_private.h
  
  Index: apr_private.h
  ===================================================================
  RCS file: /home/cvs/apr/include/arch/netware/apr_private.h,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- apr_private.h	31 Jan 2002 18:56:35 -0000	1.5
  +++ apr_private.h	8 Feb 2002 19:13:43 -0000	1.6
  @@ -174,5 +174,8 @@
   #undef malloc
   #define malloc(x) library_malloc(gLibHandle,x)
   
  +/* Changes that are waiting for an updated runtime library. */
  +#define WAITING_FOR_UPDATE
  +
   #endif  /*APR_PRIVATE_H*/
   #endif  /*NETWARE*/
  
  
  

Mime
View raw message