~ubuntu-branches/ubuntu/saucy/apr-util/saucy-proposed

« back to all changes in this revision

Viewing changes to misc/apr_thread_pool.c

  • Committer: Bazaar Package Importer
  • Author(s): Stefan Fritsch
  • Date: 2011-05-22 01:27:59 UTC
  • mfrom: (1.3.2 upstream)
  • Revision ID: james.westby@ubuntu.com-20110522012759-i80zd90uo6q1z4gr
Tags: 1.3.12+dfsg-1
* New upstream version
* Make apu-config not output dbm libs by default. Closes: #622081
* Set DEB_GCC_NO_O3=1 for the benefit of ppc64 on Ubuntu.

Show diffs side-by-side

added added

removed removed

Lines of Context:
329
329
 
330
330
static apr_status_t thread_pool_cleanup(void *me)
331
331
{
332
 
    apr_thread_pool_t *_self = me;
 
332
    apr_thread_pool_t *_myself = me;
333
333
 
334
 
    _self->terminated = 1;
335
 
    apr_thread_pool_idle_max_set(_self, 0);
336
 
    while (_self->thd_cnt) {
 
334
    _myself->terminated = 1;
 
335
    apr_thread_pool_idle_max_set(_myself, 0);
 
336
    while (_myself->thd_cnt) {
337
337
        apr_sleep(20 * 1000);   /* spin lock with 20 ms */
338
338
    }
339
 
    apr_thread_mutex_destroy(_self->lock);
340
 
    apr_thread_cond_destroy(_self->cond);
 
339
    apr_thread_mutex_destroy(_myself->lock);
 
340
    apr_thread_cond_destroy(_myself->cond);
341
341
    return APR_SUCCESS;
342
342
}
343
343