Changeset 545

Show
Ignore:
Timestamp:
12/28/06 02:34:24 (2 years ago)
Author:
alo
Message:

--

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • cherokee/trunk/ChangeLog

    r544 r545  
     12006-12-28  Alvaro Lopez Ortega  <alvaro@alobbs.com> 
     2 
     3        * cherokee/virtual_server.h, cherokee/regex.c, 
     4        cherokee/balancer_round_robin.h, cherokee/nonce.c, 
     5        cherokee/fcgi_dispatcher.h, cherokee/server-protected.h, 
     6        cherokee/logger.c, cherokee/iocache.c: Replaced #ifdef 
     7        HAVE_PTHREAD with the new CHEROKEE_{RWLOCK,MUTEX}_T macros. 
     8 
    192006-12-27  Alvaro Lopez Ortega  <alvaro@alobbs.com> 
    210 
  • cherokee/trunk/cherokee/balancer_round_robin.h

    r540 r545  
    3333        cherokee_balancer_t  balancer; 
    3434 
    35         cuint_t              last_one; 
    36 #ifdef HAVE_PTHREAD 
    37         pthread_mutex_t      last_one_mutex; 
    38 #endif   
     35        cuint_t              last_one;   
     36        CHEROKEE_MUTEX_T    (last_one_mutex); 
    3937} cherokee_balancer_round_robin_t; 
    4038 
  • cherokee/trunk/cherokee/fcgi_dispatcher.h

    r387 r545  
    3939        cherokee_list_t          queue; 
    4040        cherokee_thread_t       *thread; 
    41  
    42 #ifdef HAVE_PTHREAD 
    43         pthread_mutex_t          lock; 
    44 #endif 
     41        CHEROKEE_MUTEX_T        (lock); 
    4542} cherokee_fcgi_dispatcher_t; 
    4643 
  • cherokee/trunk/cherokee/iocache.c

    r497 r545  
    6767        cint_t                   ref_counter; 
    6868        cint_t                   usages; 
    69  
    70 #ifdef HAVE_PTHREAD 
    71         pthread_mutex_t          lock; 
    72 #endif 
     69        CHEROKEE_MUTEX_T        (lock); 
    7370} cherokee_iocache_entry_extension_t; 
    7471 
     
    7976        cuint_t            files_num; 
    8077        cuint_t            files_usages; 
    81  
    82 #ifdef HAVE_PTHREAD 
    83         pthread_mutex_t    files_lock; 
    84 #endif   
     78        CHEROKEE_MUTEX_T  (files_lock); 
    8579}; 
    8680 
  • cherokee/trunk/cherokee/logger.c

    r476 r545  
    3535 
    3636struct cherokee_logger_private { 
    37         /* Mutex 
    38          */ 
    39 #ifdef HAVE_PTHREAD 
    40         pthread_mutex_t mutex; 
    41 #endif 
    42  
    43         cherokee_boolean_t backup_mode; 
     37        CHEROKEE_MUTEX_T   (mutex); 
     38        cherokee_boolean_t  backup_mode; 
    4439}; 
    4540 
  • cherokee/trunk/cherokee/nonce.c

    r122 r545  
    2929 
    3030struct cherokee_nonce_table { 
    31         cherokee_table_t table; 
    32  
    33 #ifdef HAVE_PTHREAD 
    34         pthread_mutex_t access; 
    35 #endif 
     31        cherokee_table_t  table; 
     32        CHEROKEE_MUTEX_T (access); 
    3633}; 
    3734 
  • cherokee/trunk/cherokee/regex.c

    r122 r545  
    3030 
    3131struct cherokee_regex_table { 
    32         cherokee_table_t *cache; 
    33 #ifdef HAVE_PTHREAD 
    34         pthread_rwlock_t rwlock; 
    35 #endif 
     32        cherokee_table_t   *cache; 
     33        CHEROKEE_RWLOCK_T  (rwlock); 
    3634}; 
    3735 
  • cherokee/trunk/cherokee/server-protected.h

    r541 r545  
    6666        struct tm                    bogo_now_tm; 
    6767        cherokee_buffer_t            bogo_now_string; 
    68 #ifdef HAVE_PTHREAD 
    69         pthread_rwlock_t             bogo_now_mutex; 
    70 #endif 
     68        CHEROKEE_RWLOCK_T           (bogo_now_mutex); 
    7169 
    7270        /* Exit related 
     
    112110        cherokee_socket_t          socket_tls; 
    113111 
    114 #ifdef HAVE_PTHREAD 
    115         pthread_mutex_t            accept_mutex; 
    116 # ifdef HAVE_TLS 
    117         pthread_mutex_t            accept_tls_mutex;     
    118 # endif 
     112        CHEROKEE_MUTEX_T          (accept_mutex); 
     113#ifdef HAVE_TLS 
     114        CHEROKEE_MUTEX_T          (accept_tls_mutex); 
    119115#endif 
    120116 
  • cherokee/trunk/cherokee/virtual_server.h

    r438 r545  
    6868                size_t               tx; 
    6969                size_t               rx; 
    70  
    71 #ifdef HAVE_PTHREAD 
    72                 pthread_mutex_t      tx_mutex; 
    73                 pthread_mutex_t      rx_mutex; 
    74 #endif 
     70                CHEROKEE_MUTEX_T    (tx_mutex); 
     71                CHEROKEE_MUTEX_T    (rx_mutex); 
    7572        } data; 
    7673