Don't queue delete_ike_sa job when setting IKE_DELETING.
authorTobias Brunner <tobias@strongswan.org>
Wed, 9 May 2012 13:28:29 +0000 (15:28 +0200)
committerTobias Brunner <tobias@strongswan.org>
Fri, 25 May 2012 15:05:53 +0000 (17:05 +0200)
This avoids deleting IKE_SAs during reauthentication (without
trying to reestablish them).

src/libcharon/sa/ike_sa.c
src/libcharon/sa/ikev2/tasks/ike_delete.c

index fc69ecb..926e2d1 100644 (file)
@@ -678,14 +678,6 @@ METHOD(ike_sa_t, set_state, void,
                        }
                        break;
                }
-               case IKE_DELETING:
-               {
-                       /* delete may fail if a packet gets lost, so set a timeout */
-                       job_t *job = (job_t*)delete_ike_sa_job_create(this->ike_sa_id, TRUE);
-                       lib->scheduler->schedule_job(lib->scheduler, job,
-                                                                                HALF_OPEN_IKE_SA_TIMEOUT);
-                       break;
-               }
                default:
                        break;
        }
index 29ac872..f127b0c 100644 (file)
@@ -135,7 +135,7 @@ METHOD(task_t, build_r, status_t,
 
        if (this->simultaneous)
        {
-               /* wait for peer's response for our delete request, but set a timeout */
+               /* wait for peer's response for our delete request */
                return SUCCESS;
        }
        if (!this->rekeyed)