diff options
| author | Tobias Brunner <tobias@strongswan.org> | 2015-11-06 14:45:57 +0100 |
|---|---|---|
| committer | Tobias Brunner <tobias@strongswan.org> | 2015-11-09 15:18:38 +0100 |
| commit | 4ae29195186e39702f7448bc33a4af47423e9ec2 (patch) | |
| tree | 957764b61e167202d8d4c1a64e8d31831884fdbe /src/libcharon/processing | |
| parent | bcad0f761f39e4f9709611f6c2ab9674ea023613 (diff) | |
| download | strongswan-4ae29195186e39702f7448bc33a4af47423e9ec2.tar.bz2 strongswan-4ae29195186e39702f7448bc33a4af47423e9ec2.tar.xz | |
mediation: Reschedule initiate mediation job if SA is not yet found
If the job gets queued for a newly created IKE_SA it might not yet be
checked in when the job is running, reschedule the job in that case.
This should fix the two p2pnat test scenarios, which occasionally
failed because one of the peers did not initiate the connection to
the mediation server.
Diffstat (limited to 'src/libcharon/processing')
| -rw-r--r-- | src/libcharon/processing/jobs/initiate_mediation_job.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/libcharon/processing/jobs/initiate_mediation_job.c b/src/libcharon/processing/jobs/initiate_mediation_job.c index 5b5fb9d98..6c01ffe95 100644 --- a/src/libcharon/processing/jobs/initiate_mediation_job.c +++ b/src/libcharon/processing/jobs/initiate_mediation_job.c @@ -161,6 +161,10 @@ METHOD(job_t, initiate, job_requeue_t, } mediated_cfg->destroy(mediated_cfg); } + else + { /* newly created IKE_SA is not checked in yet, try again */ + return JOB_RESCHEDULE_MS(100); + } return JOB_REQUEUE_NONE; } |
