peer-cfg: Use flags for boolean options

Makes it potentially easier to add new flags.

The mediation flag is not converted as the #ifdefs make it awkward.
This commit is contained in:
Tobias Brunner
2025-04-10 08:31:09 +02:00
parent b0a4b7f2dd
commit 6ed63be612
22 changed files with 174 additions and 167 deletions
+1 -1
View File
@@ -2100,7 +2100,7 @@ static message_t *create_fragment(private_message_t *this, payload_type_t next,
* or transaction messages. */
ike_sa = charon->bus->get_sa(charon->bus);
if (ike_sa && (peer_cfg = ike_sa->get_peer_cfg(ike_sa)) &&
peer_cfg->use_aggressive(peer_cfg))
peer_cfg->has_option(peer_cfg, OPT_IKEV1_AGGRESSIVE))
{
message->set_exchange_type(message, AGGRESSIVE);
}