Correct check of traffic selectors before destruction

This commit is contained in:
Thomas Egerer
2010-06-29 09:22:50 +02:00
committed by Martin Willi
parent 7f1eb89517
commit 6d61e334f7
+2 -2
View File
@@ -1229,11 +1229,11 @@ static void migrate(private_child_create_t *this, ike_sa_t *ike_sa)
{
chunk_free(&this->my_nonce);
chunk_free(&this->other_nonce);
if (this->tsi)
if (this->tsr)
{
this->tsr->destroy_offset(this->tsr, offsetof(traffic_selector_t, destroy));
}
if (this->tsr)
if (this->tsi)
{
this->tsi->destroy_offset(this->tsi, offsetof(traffic_selector_t, destroy));
}