diff options
author | Martin Willi <martin@revosec.ch> | 2013-07-18 11:40:40 +0200 |
---|---|---|
committer | Martin Willi <martin@revosec.ch> | 2013-07-18 16:00:31 +0200 |
commit | ea009869e9e5cc914c5ce98261351029c7ab079e (patch) | |
tree | 85c58609647e26811bbb8c3d068c3e3ad578db91 /src/libstrongswan/processing | |
parent | 6653e6c13e61da0753625af13de62c46d1ceeb48 (diff) | |
download | strongswan-ea009869e9e5cc914c5ce98261351029c7ab079e.tar.bz2 strongswan-ea009869e9e5cc914c5ce98261351029c7ab079e.tar.xz |
watcher: use processors new execute_job() to notify FDs
Just queueing is problematic, as all threads might be busy waiting for events
that the queued (but never executed) job delivers.
Diffstat (limited to 'src/libstrongswan/processing')
-rw-r--r-- | src/libstrongswan/processing/watcher.c | 10 |
1 files changed, 1 insertions, 9 deletions
diff --git a/src/libstrongswan/processing/watcher.c b/src/libstrongswan/processing/watcher.c index 9e02a1b49..69cb3c8f5 100644 --- a/src/libstrongswan/processing/watcher.c +++ b/src/libstrongswan/processing/watcher.c @@ -325,15 +325,7 @@ static job_requeue_t watch(private_watcher_t *this) while (this->jobs->remove_first(this->jobs, (void**)&job) == SUCCESS) { - if (lib->processor->get_threads(lib->processor)) - { - lib->processor->queue_job(lib->processor, job); - } - else - { - job->execute(job); - job->destroy(job); - } + lib->processor->execute_job(lib->processor, job); } /* we temporarily disable a notified FD, rebuild FDSET */ return JOB_REQUEUE_DIRECT; |