apr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jerenkra...@apache.org
Subject cvs commit: apr-util/misc apr_queue.c
Date Mon, 23 Dec 2002 20:36:24 GMT
jerenkrantz    2002/12/23 12:36:24

  Modified:    .        CHANGES
               include  apr_queue.h
               misc     apr_queue.c
  Log:
  Allow apr_queue to have greater than int number of elements.
  (serf_spider needs a ridicuously large queue size.)
  
  Revision  Changes    Path
  1.90      +3 -0      apr-util/CHANGES
  
  Index: CHANGES
  ===================================================================
  RCS file: /home/cvs/apr-util/CHANGES,v
  retrieving revision 1.89
  retrieving revision 1.90
  diff -u -u -r1.89 -r1.90
  --- CHANGES	19 Dec 2002 02:16:09 -0000	1.89
  +++ CHANGES	23 Dec 2002 20:36:23 -0000	1.90
  @@ -1,5 +1,8 @@
   Changes with APR-util 0.9.2
   
  +  *) Allow apr_queue to have greater than int number of elements.
  +     [Justin Erenkrantz]
  +
     *) Detect Berkeley DB 4.0 compiled with --with-uniquenames.
        [Philip Martin <philip@codematters.co.uk>]
   
  
  
  
  1.6       +2 -2      apr-util/include/apr_queue.h
  
  Index: apr_queue.h
  ===================================================================
  RCS file: /home/cvs/apr-util/include/apr_queue.h,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -u -r1.5 -r1.6
  --- apr_queue.h	22 Dec 2002 21:53:24 -0000	1.5
  +++ apr_queue.h	23 Dec 2002 20:36:23 -0000	1.6
  @@ -94,7 +94,7 @@
    * @param a pool to allocate queue from
    */
   APU_DECLARE(apr_status_t) apr_queue_create(apr_queue_t **queue, 
  -                                           int queue_capacity, 
  +                                           apr_size_t queue_capacity, 
                                              apr_pool_t *a);
   
   /**
  @@ -151,7 +151,7 @@
    * @param queue the queue
    * @returns the size of the queue
    */
  -APU_DECLARE(int) apr_queue_size(apr_queue_t *queue);
  +APU_DECLARE(apr_size_t) apr_queue_size(apr_queue_t *queue);
   
   /**
    * interrupt all the threads blocking on this queue.
  
  
  
  1.7       +6 -6      apr-util/misc/apr_queue.c
  
  Index: apr_queue.c
  ===================================================================
  RCS file: /home/cvs/apr-util/misc/apr_queue.c,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -u -r1.6 -r1.7
  --- apr_queue.c	23 Dec 2002 20:31:25 -0000	1.6
  +++ apr_queue.c	23 Dec 2002 20:36:24 -0000	1.7
  @@ -81,10 +81,10 @@
   
   struct apr_queue_t {
       void              **data;
  -    int                 nelts; /**< # elements */
  -    int                 in;    /**< next empty location */
  -    int                 out;   /**< next filled location */
  -    int                 bounds;/**< max size of queue */
  +    apr_size_t          nelts; /**< # elements */
  +    apr_size_t          in;    /**< next empty location */
  +    apr_size_t          out;   /**< next filled location */
  +    apr_size_t          bounds;/**< max size of queue */
       apr_thread_mutex_t *one_big_mutex;
       apr_thread_cond_t  *not_empty;
       apr_thread_cond_t  *not_full;
  @@ -136,7 +136,7 @@
    * Initialize the apr_queue_t.
    */
   APU_DECLARE(apr_status_t) apr_queue_create(apr_queue_t **q, 
  -                                           int queue_capacity, 
  +                                           apr_size_t queue_capacity, 
                                              apr_pool_t *a)
   {
       apr_status_t rv;
  @@ -288,7 +288,7 @@
   /**
    * not thread safe
    */
  -APU_DECLARE(int) apr_queue_size(apr_queue_t *queue) {
  +APU_DECLARE(apr_size_t) apr_queue_size(apr_queue_t *queue) {
       return queue->nelts;
   }
   
  
  
  

Mime
View raw message