updown: Return an empty DNS server enumerator if no IKE_SA available
The one existing caller does not handle a NULL return and always expects an enumerator; and returning FALSE does not make sense anyway.
This commit is contained in:
@@ -188,7 +188,7 @@ METHOD(updown_handler_t, create_dns_enumerator, enumerator_t*,
|
|||||||
ike_sa = charon->bus->get_sa(charon->bus);
|
ike_sa = charon->bus->get_sa(charon->bus);
|
||||||
if (!ike_sa)
|
if (!ike_sa)
|
||||||
{
|
{
|
||||||
return FALSE;
|
return enumerator_create_empty();
|
||||||
}
|
}
|
||||||
|
|
||||||
this->lock->read_lock(this->lock);
|
this->lock->read_lock(this->lock);
|
||||||
|
|||||||
Reference in New Issue
Block a user