diff --git a/src/libcharon/bus/bus.c b/src/libcharon/bus/bus.c index 441009e5e..d017c2a97 100644 --- a/src/libcharon/bus/bus.c +++ b/src/libcharon/bus/bus.c @@ -17,7 +17,7 @@ #include -#include +#include #include #include #include @@ -163,7 +163,7 @@ METHOD(bus_t, listen_, void, this->mutex->lock(this->mutex); this->listeners->insert_last(this->listeners, data.entry); - charon->processor->queue_job(charon->processor, job); + hydra->processor->queue_job(hydra->processor, job); thread_cleanup_push((thread_cleanup_t)this->mutex->unlock, this->mutex); thread_cleanup_push((thread_cleanup_t)listener_cleanup, &data); old = thread_cancelability(TRUE); diff --git a/src/libcharon/daemon.c b/src/libcharon/daemon.c index 2f4c1c1fa..f414db96e 100644 --- a/src/libcharon/daemon.c +++ b/src/libcharon/daemon.c @@ -32,6 +32,7 @@ #include "daemon.h" #include +#include #include #ifndef LOG_AUTHPRIV /* not defined on OpenSolaris */ diff --git a/src/libcharon/network/receiver.c b/src/libcharon/network/receiver.c index 1a25d457d..cc73ba89e 100644 --- a/src/libcharon/network/receiver.c +++ b/src/libcharon/network/receiver.c @@ -20,6 +20,7 @@ #include "receiver.h" +#include #include #include #include @@ -360,7 +361,7 @@ static job_requeue_t receive_packets(private_receiver_t *this) } } } - charon->processor->queue_job(charon->processor, + hydra->processor->queue_job(hydra->processor, (job_t*)process_message_job_create(message)); return JOB_REQUEUE_DIRECT; } @@ -426,7 +427,7 @@ receiver_t *receiver_create() this->job = callback_job_create((callback_job_cb_t)receive_packets, this, NULL, NULL); - charon->processor->queue_job(charon->processor, (job_t*)this->job); + hydra->processor->queue_job(hydra->processor, (job_t*)this->job); return &this->public; } diff --git a/src/libcharon/network/sender.c b/src/libcharon/network/sender.c index bb6d50605..541384270 100644 --- a/src/libcharon/network/sender.c +++ b/src/libcharon/network/sender.c @@ -19,6 +19,7 @@ #include "sender.h" +#include #include #include #include @@ -195,7 +196,7 @@ sender_t * sender_create() "charon.send_delay_response", TRUE), ); - charon->processor->queue_job(charon->processor, (job_t*)this->job); + hydra->processor->queue_job(hydra->processor, (job_t*)this->job); return &this->public; } diff --git a/src/libcharon/plugins/android/android_service.c b/src/libcharon/plugins/android/android_service.c index 538c4a9a2..235679a15 100644 --- a/src/libcharon/plugins/android/android_service.c +++ b/src/libcharon/plugins/android/android_service.c @@ -20,6 +20,7 @@ #include "android_service.h" +#include #include #include #include @@ -378,7 +379,7 @@ android_service_t *android_service_create(android_creds_t *creds) charon->bus->add_listener(charon->bus, &this->public.listener); this->job = callback_job_create((callback_job_cb_t)initiate, this, NULL, NULL); - charon->processor->queue_job(charon->processor, (job_t*)this->job); + hydra->processor->queue_job(hydra->processor, (job_t*)this->job); return &this->public; } diff --git a/src/libcharon/plugins/dhcp/dhcp_socket.c b/src/libcharon/plugins/dhcp/dhcp_socket.c index f61b3a60e..4a6b4514a 100644 --- a/src/libcharon/plugins/dhcp/dhcp_socket.c +++ b/src/libcharon/plugins/dhcp/dhcp_socket.c @@ -31,6 +31,7 @@ #include #include +#include #include #include @@ -751,7 +752,7 @@ dhcp_socket_t *dhcp_socket_create() this->job = callback_job_create((callback_job_cb_t)receive_dhcp, this, NULL, NULL); - charon->processor->queue_job(charon->processor, (job_t*)this->job); + hydra->processor->queue_job(hydra->processor, (job_t*)this->job); return &this->public; } diff --git a/src/libcharon/plugins/farp/farp_spoofer.c b/src/libcharon/plugins/farp/farp_spoofer.c index 20bb44fd3..031f47687 100644 --- a/src/libcharon/plugins/farp/farp_spoofer.c +++ b/src/libcharon/plugins/farp/farp_spoofer.c @@ -23,6 +23,7 @@ #include #include +#include #include #include #include @@ -191,7 +192,7 @@ farp_spoofer_t *farp_spoofer_create(farp_listener_t *listener) this->job = callback_job_create((callback_job_cb_t)receive_arp, this, NULL, NULL); - charon->processor->queue_job(charon->processor, (job_t*)this->job); + hydra->processor->queue_job(hydra->processor, (job_t*)this->job); return &this->public; } diff --git a/src/libcharon/plugins/ha/ha_ctl.c b/src/libcharon/plugins/ha/ha_ctl.c index e188a8484..781918c0a 100644 --- a/src/libcharon/plugins/ha/ha_ctl.c +++ b/src/libcharon/plugins/ha/ha_ctl.c @@ -23,6 +23,7 @@ #include #include +#include #include #define HA_FIFO IPSEC_PIDDIR "/charon.ha" @@ -134,7 +135,7 @@ ha_ctl_t *ha_ctl_create(ha_segments_t *segments, ha_cache_t *cache) this->job = callback_job_create((callback_job_cb_t)dispatch_fifo, this, NULL, NULL); - charon->processor->queue_job(charon->processor, (job_t*)this->job); + hydra->processor->queue_job(hydra->processor, (job_t*)this->job); return &this->public; } diff --git a/src/libcharon/plugins/ha/ha_dispatcher.c b/src/libcharon/plugins/ha/ha_dispatcher.c index 3bc426ea0..b6007b84b 100644 --- a/src/libcharon/plugins/ha/ha_dispatcher.c +++ b/src/libcharon/plugins/ha/ha_dispatcher.c @@ -15,6 +15,7 @@ #include "ha_dispatcher.h" +#include #include #include @@ -869,7 +870,7 @@ ha_dispatcher_t *ha_dispatcher_create(ha_socket_t *socket, ); this->job = callback_job_create((callback_job_cb_t)dispatch, this, NULL, NULL); - charon->processor->queue_job(charon->processor, (job_t*)this->job); + hydra->processor->queue_job(hydra->processor, (job_t*)this->job); return &this->public; } diff --git a/src/libcharon/plugins/ha/ha_segments.c b/src/libcharon/plugins/ha/ha_segments.c index c8c20859b..8d6fff439 100644 --- a/src/libcharon/plugins/ha/ha_segments.c +++ b/src/libcharon/plugins/ha/ha_segments.c @@ -17,6 +17,7 @@ #include +#include #include #include #include @@ -283,7 +284,7 @@ static void start_watchdog(private_ha_segments_t *this) { this->job = callback_job_create((callback_job_cb_t)watchdog, this, NULL, NULL); - charon->processor->queue_job(charon->processor, (job_t*)this->job); + hydra->processor->queue_job(hydra->processor, (job_t*)this->job); } METHOD(ha_segments_t, handle_status, void, diff --git a/src/libcharon/plugins/ha/ha_socket.c b/src/libcharon/plugins/ha/ha_socket.c index 21e6eb6d5..50c10b9ef 100644 --- a/src/libcharon/plugins/ha/ha_socket.c +++ b/src/libcharon/plugins/ha/ha_socket.c @@ -22,6 +22,7 @@ #include #include +#include #include #include #include @@ -107,7 +108,7 @@ METHOD(ha_socket_t, push, void, job = callback_job_create((callback_job_cb_t)send_message, data, (void*)job_data_destroy, NULL); - charon->processor->queue_job(charon->processor, (job_t*)job); + hydra->processor->queue_job(hydra->processor, (job_t*)job); return; } DBG1(DBG_CFG, "pushing HA message failed: %s", strerror(errno)); diff --git a/src/libcharon/plugins/kernel_klips/kernel_klips_ipsec.c b/src/libcharon/plugins/kernel_klips/kernel_klips_ipsec.c index f8a5d5bcb..81e46dad3 100644 --- a/src/libcharon/plugins/kernel_klips/kernel_klips_ipsec.c +++ b/src/libcharon/plugins/kernel_klips/kernel_klips_ipsec.c @@ -28,6 +28,7 @@ #include "kernel_klips_ipsec.h" +#include #include #include #include @@ -1300,7 +1301,7 @@ static void process_acquire(private_kernel_klips_ipsec_t *this, struct sadb_msg* DBG2(DBG_KNL, "received an SADB_ACQUIRE"); DBG1(DBG_KNL, "creating acquire job for CHILD_SA with reqid {%d}", reqid); job = (job_t*)acquire_job_create(reqid, NULL, NULL); - charon->processor->queue_job(charon->processor, job); + hydra->processor->queue_job(hydra->processor, job); } /** @@ -1363,7 +1364,7 @@ static void process_mapping(private_kernel_klips_ipsec_t *this, struct sadb_msg* DBG1(DBG_KNL, "NAT mappings of ESP CHILD_SA with SPI %.8x and" " reqid {%d} changed, queuing update job", ntohl(spi), reqid); job = (job_t*)update_sa_job_create(reqid, new_src); - charon->processor->queue_job(charon->processor, job); + hydra->processor->queue_job(hydra->processor, job); } } } @@ -1510,7 +1511,7 @@ static job_requeue_t sa_expires(sa_expire_t *expire) { job = (job_t*)rekey_child_sa_job_create(reqid, protocol, spi); } - charon->processor->queue_job(charon->processor, job); + hydra->processor->queue_job(hydra->processor, job); return JOB_REQUEUE_NONE; } @@ -2655,7 +2656,7 @@ kernel_klips_ipsec_t *kernel_klips_ipsec_create() this->job = callback_job_create((callback_job_cb_t)receive_events, this, NULL, NULL); - charon->processor->queue_job(charon->processor, (job_t*)this->job); + hydra->processor->queue_job(hydra->processor, (job_t*)this->job); return &this->public; } diff --git a/src/libcharon/plugins/kernel_netlink/kernel_netlink_ipsec.c b/src/libcharon/plugins/kernel_netlink/kernel_netlink_ipsec.c index dcd6871c1..9ba539175 100644 --- a/src/libcharon/plugins/kernel_netlink/kernel_netlink_ipsec.c +++ b/src/libcharon/plugins/kernel_netlink/kernel_netlink_ipsec.c @@ -35,6 +35,7 @@ #include "kernel_netlink_ipsec.h" #include "kernel_netlink_shared.h" +#include #include #include #include @@ -296,7 +297,7 @@ struct policy_entry_t { static u_int policy_hash(policy_entry_t *key) { chunk_t chunk = chunk_create((void*)&key->sel, - sizeof(struct xfrm_selector) + sizeof(u_int32_t)); + sizeof(struct xfrm_selector) + sizeof(u_int32_t)); return chunk_hash(chunk); } @@ -593,7 +594,7 @@ static void process_acquire(private_kernel_netlink_ipsec_t *this, struct nlmsghd DBG1(DBG_KNL, "creating acquire job for policy %R === %R with reqid {%u}", src_ts, dst_ts, reqid); job = (job_t*)acquire_job_create(reqid, src_ts, dst_ts); - charon->processor->queue_job(charon->processor, job); + hydra->processor->queue_job(hydra->processor, job); } /** @@ -631,7 +632,7 @@ static void process_expire(private_kernel_netlink_ipsec_t *this, struct nlmsghdr { job = (job_t*)rekey_child_sa_job_create(reqid, protocol, spi); } - charon->processor->queue_job(charon->processor, job); + hydra->processor->queue_job(hydra->processor, job); } /** @@ -703,7 +704,7 @@ static void process_migrate(private_kernel_netlink_ipsec_t *this, struct nlmsghd src_ts, dst_ts, policy_dir_names, dir, reqid, local); job = (job_t*)migrate_job_create(reqid, src_ts, dst_ts, dir, local, remote); - charon->processor->queue_job(charon->processor, job); + hydra->processor->queue_job(hydra->processor, job); } else { @@ -740,7 +741,7 @@ static void process_mapping(private_kernel_netlink_ipsec_t *this, DBG1(DBG_KNL, "NAT mappings of ESP CHILD_SA with SPI %.8x and " "reqid {%u} changed, queuing update job", ntohl(spi), reqid); job = (job_t*)update_sa_job_create(reqid, host); - charon->processor->queue_job(charon->processor, job); + hydra->processor->queue_job(hydra->processor, job); } } } @@ -1705,7 +1706,7 @@ METHOD(kernel_ipsec_t, add_policy, status_t, DBG2(DBG_KNL, "policy %R === %R %N (mark %u/0x%8x) " "already exists, increasing refcount", src_ts, dst_ts, policy_dir_names, direction, - mark.value, mark.mask); + mark.value, mark.mask); } else { @@ -2260,7 +2261,7 @@ kernel_netlink_ipsec_t *kernel_netlink_ipsec_create() } this->job = callback_job_create((callback_job_cb_t)receive_events, this, NULL, NULL); - charon->processor->queue_job(charon->processor, (job_t*)this->job); + hydra->processor->queue_job(hydra->processor, (job_t*)this->job); return &this->public; } diff --git a/src/libcharon/plugins/kernel_netlink/kernel_netlink_net.c b/src/libcharon/plugins/kernel_netlink/kernel_netlink_net.c index 6750458cf..5240d3d22 100644 --- a/src/libcharon/plugins/kernel_netlink/kernel_netlink_net.c +++ b/src/libcharon/plugins/kernel_netlink/kernel_netlink_net.c @@ -47,6 +47,7 @@ #include "kernel_netlink_net.h" #include "kernel_netlink_shared.h" +#include #include #include #include @@ -1479,7 +1480,7 @@ kernel_netlink_net_t *kernel_netlink_net_create() this->job = callback_job_create((callback_job_cb_t)receive_events, this, NULL, NULL); - charon->processor->queue_job(charon->processor, (job_t*)this->job); + hydra->processor->queue_job(hydra->processor, (job_t*)this->job); if (init_address_list(this) != SUCCESS) { diff --git a/src/libcharon/plugins/kernel_pfkey/kernel_pfkey_ipsec.c b/src/libcharon/plugins/kernel_pfkey/kernel_pfkey_ipsec.c index b01f627fa..6773dcf87 100644 --- a/src/libcharon/plugins/kernel_pfkey/kernel_pfkey_ipsec.c +++ b/src/libcharon/plugins/kernel_pfkey/kernel_pfkey_ipsec.c @@ -54,6 +54,7 @@ #include "kernel_pfkey_ipsec.h" +#include #include #include #include @@ -940,7 +941,7 @@ static void process_acquire(private_kernel_pfkey_ipsec_t *this, struct sadb_msg* DBG1(DBG_KNL, "creating acquire job for policy %R === %R with reqid {%u}", src_ts, dst_ts, reqid); job = (job_t*)acquire_job_create(reqid, src_ts, dst_ts); - charon->processor->queue_job(charon->processor, job); + hydra->processor->queue_job(hydra->processor, job); } /** @@ -985,7 +986,7 @@ static void process_expire(private_kernel_pfkey_ipsec_t *this, struct sadb_msg* { job = (job_t*)rekey_child_sa_job_create(reqid, protocol, spi); } - charon->processor->queue_job(charon->processor, job); + hydra->processor->queue_job(hydra->processor, job); } #ifdef SADB_X_MIGRATE @@ -1035,7 +1036,7 @@ static void process_migrate(private_kernel_pfkey_ipsec_t *this, struct sadb_msg* src_ts, dst_ts, policy_dir_names, dir, reqid, local); job = (job_t*)migrate_job_create(reqid, src_ts, dst_ts, dir, local, remote); - charon->processor->queue_job(charon->processor, job); + hydra->processor->queue_job(hydra->processor, job); } else { @@ -1099,7 +1100,7 @@ static void process_mapping(private_kernel_pfkey_ipsec_t *this, struct sadb_msg* DBG1(DBG_KNL, "NAT mappings of ESP CHILD_SA with SPI %.8x and " "reqid {%u} changed, queuing update job", ntohl(spi), reqid); job = (job_t*)update_sa_job_create(reqid, host); - charon->processor->queue_job(charon->processor, job); + hydra->processor->queue_job(hydra->processor, job); } } } @@ -2205,7 +2206,7 @@ kernel_pfkey_ipsec_t *kernel_pfkey_ipsec_create() this->job = callback_job_create((callback_job_cb_t)receive_events, this, NULL, NULL); - charon->processor->queue_job(charon->processor, (job_t*)this->job); + hydra->processor->queue_job(hydra->processor, (job_t*)this->job); return &this->public; } diff --git a/src/libcharon/plugins/kernel_pfroute/kernel_pfroute_net.c b/src/libcharon/plugins/kernel_pfroute/kernel_pfroute_net.c index 97c019b58..6c06b6292 100644 --- a/src/libcharon/plugins/kernel_pfroute/kernel_pfroute_net.c +++ b/src/libcharon/plugins/kernel_pfroute/kernel_pfroute_net.c @@ -23,6 +23,7 @@ #include "kernel_pfroute_net.h" +#include #include #include #include @@ -716,7 +717,7 @@ kernel_pfroute_net_t *kernel_pfroute_net_create() this->job = callback_job_create((callback_job_cb_t)receive_events, this, NULL, NULL); - charon->processor->queue_job(charon->processor, (job_t*)this->job); + hydra->processor->queue_job(hydra->processor, (job_t*)this->job); if (init_address_list(this) != SUCCESS) { diff --git a/src/libcharon/plugins/load_tester/load_tester_listener.c b/src/libcharon/plugins/load_tester/load_tester_listener.c index 96b0cf1ec..19a38d90e 100644 --- a/src/libcharon/plugins/load_tester/load_tester_listener.c +++ b/src/libcharon/plugins/load_tester/load_tester_listener.c @@ -17,6 +17,7 @@ #include +#include #include #include @@ -59,7 +60,7 @@ static bool ike_state_change(private_load_tester_listener_t *this, if (this->delete_after_established) { - charon->processor->queue_job(charon->processor, + hydra->processor->queue_job(hydra->processor, (job_t*)delete_ike_sa_job_create(id, TRUE)); } diff --git a/src/libcharon/plugins/load_tester/load_tester_plugin.c b/src/libcharon/plugins/load_tester/load_tester_plugin.c index 15dbccb00..c9384d558 100644 --- a/src/libcharon/plugins/load_tester/load_tester_plugin.c +++ b/src/libcharon/plugins/load_tester/load_tester_plugin.c @@ -22,6 +22,7 @@ #include +#include #include #include #include @@ -221,7 +222,7 @@ plugin_t *load_tester_plugin_create() this->running = 0; for (i = 0; i < this->initiators; i++) { - charon->processor->queue_job(charon->processor, + hydra->processor->queue_job(hydra->processor, (job_t*)callback_job_create((callback_job_cb_t)do_load_test, this, NULL, NULL)); } diff --git a/src/libcharon/plugins/medcli/medcli_config.c b/src/libcharon/plugins/medcli/medcli_config.c index 6cbaf36f2..aafe33af2 100644 --- a/src/libcharon/plugins/medcli/medcli_config.c +++ b/src/libcharon/plugins/medcli/medcli_config.c @@ -18,6 +18,7 @@ #include "medcli_config.h" +#include #include #include @@ -126,11 +127,11 @@ static peer_cfg_t *get_peer_cfg_by_name(private_medcli_config_t *this, char *nam med_cfg = peer_cfg_create( "mediation", 2, ike_cfg, CERT_NEVER_SEND, UNIQUE_REPLACE, - 1, this->rekey*60, 0, /* keytries, rekey, reauth */ - this->rekey*5, this->rekey*3, /* jitter, overtime */ - TRUE, this->dpd, /* mobike, dpddelay */ - NULL, NULL, /* vip, pool */ - TRUE, NULL, NULL); /* mediation, med by, peer id */ + 1, this->rekey*60, 0, /* keytries, rekey, reauth */ + this->rekey*5, this->rekey*3, /* jitter, overtime */ + TRUE, this->dpd, /* mobike, dpddelay */ + NULL, NULL, /* vip, pool */ + TRUE, NULL, NULL); /* mediation, med by, peer id */ e->destroy(e); auth = auth_cfg_create(); @@ -163,10 +164,10 @@ static peer_cfg_t *get_peer_cfg_by_name(private_medcli_config_t *this, char *nam peer_cfg = peer_cfg_create( name, 2, this->ike->get_ref(this->ike), CERT_NEVER_SEND, UNIQUE_REPLACE, - 1, this->rekey*60, 0, /* keytries, rekey, reauth */ - this->rekey*5, this->rekey*3, /* jitter, overtime */ - TRUE, this->dpd, /* mobike, dpddelay */ - NULL, NULL, /* vip, pool */ + 1, this->rekey*60, 0, /* keytries, rekey, reauth */ + this->rekey*5, this->rekey*3, /* jitter, overtime */ + TRUE, this->dpd, /* mobike, dpddelay */ + NULL, NULL, /* vip, pool */ FALSE, med_cfg, /* mediation, med by */ identification_create_from_encoding(ID_KEY_ID, other)); @@ -243,11 +244,11 @@ static bool peer_enumerator_enumerate(peer_enumerator_t *this, peer_cfg_t **cfg) this->current = peer_cfg_create( name, 2, this->ike->get_ref(this->ike), CERT_NEVER_SEND, UNIQUE_REPLACE, - 1, this->rekey*60, 0, /* keytries, rekey, reauth */ - this->rekey*5, this->rekey*3, /* jitter, overtime */ - TRUE, this->dpd, /* mobike, dpddelay */ - NULL, NULL, /* vip, pool */ - FALSE, NULL, NULL); /* mediation, med by, peer id */ + 1, this->rekey*60, 0, /* keytries, rekey, reauth */ + this->rekey*5, this->rekey*3, /* jitter, overtime */ + TRUE, this->dpd, /* mobike, dpddelay */ + NULL, NULL, /* vip, pool */ + FALSE, NULL, NULL); /* mediation, med by, peer id */ auth = auth_cfg_create(); auth->add(auth, AUTH_RULE_AUTH_CLASS, AUTH_CLASS_PUBKEY); @@ -364,7 +365,7 @@ static void schedule_autoinit(private_medcli_config_t *this) if (peer_cfg) { /* schedule asynchronous initiation job */ - charon->processor->queue_job(charon->processor, + hydra->processor->queue_job(hydra->processor, (job_t*)callback_job_create( (callback_job_cb_t)initiate_config, peer_cfg, (void*)peer_cfg->destroy, NULL)); diff --git a/src/libcharon/plugins/nm/nm_plugin.c b/src/libcharon/plugins/nm/nm_plugin.c index 250e6f7f9..e1da7822b 100644 --- a/src/libcharon/plugins/nm/nm_plugin.c +++ b/src/libcharon/plugins/nm/nm_plugin.c @@ -122,7 +122,7 @@ plugin_t *nm_plugin_create() /* bypass file permissions to read from users ssh-agent */ charon->keep_cap(charon, CAP_DAC_OVERRIDE); - charon->processor->queue_job(charon->processor, + hydra->processor->queue_job(hydra->processor, (job_t*)callback_job_create((callback_job_cb_t)run, this, NULL, NULL)); return &this->public.plugin; diff --git a/src/libcharon/plugins/smp/smp.c b/src/libcharon/plugins/smp/smp.c index 64820eb45..c891c3262 100644 --- a/src/libcharon/plugins/smp/smp.c +++ b/src/libcharon/plugins/smp/smp.c @@ -28,6 +28,7 @@ #include #include +#include #include #include #include @@ -702,7 +703,7 @@ static job_requeue_t dispatch(private_smp_t *this) fdp = malloc_thing(int); *fdp = fd; job = callback_job_create((callback_job_cb_t)process, fdp, free, this->job); - charon->processor->queue_job(charon->processor, (job_t*)job); + hydra->processor->queue_job(hydra->processor, (job_t*)job); return JOB_REQUEUE_DIRECT; } @@ -761,7 +762,7 @@ plugin_t *smp_plugin_create() } this->job = callback_job_create((callback_job_cb_t)dispatch, this, NULL, NULL); - charon->processor->queue_job(charon->processor, (job_t*)this->job); + hydra->processor->queue_job(hydra->processor, (job_t*)this->job); return &this->public.plugin; } diff --git a/src/libcharon/plugins/stroke/stroke_control.c b/src/libcharon/plugins/stroke/stroke_control.c index f64421551..f009d077f 100644 --- a/src/libcharon/plugins/stroke/stroke_control.c +++ b/src/libcharon/plugins/stroke/stroke_control.c @@ -15,6 +15,7 @@ #include "stroke_control.h" +#include #include #include @@ -354,7 +355,7 @@ static void terminate_srcip(private_stroke_control_t *this, } /* schedule delete asynchronously */ - charon->processor->queue_job(charon->processor, (job_t*) + hydra->processor->queue_job(hydra->processor, (job_t*) delete_ike_sa_job_create(ike_sa->get_id(ike_sa), TRUE)); } enumerator->destroy(enumerator); diff --git a/src/libcharon/plugins/stroke/stroke_list.c b/src/libcharon/plugins/stroke/stroke_list.c index bd891811d..9106a4fe5 100644 --- a/src/libcharon/plugins/stroke/stroke_list.c +++ b/src/libcharon/plugins/stroke/stroke_list.c @@ -21,6 +21,7 @@ #include #endif /* HAVE_MALLINFO */ +#include #include #include #include @@ -422,10 +423,10 @@ static void status(private_stroke_list_t *this, stroke_msg_t *msg, FILE *out, bo } #endif /* HAVE_MALLINFO */ fprintf(out, " worker threads: %d idle of %d,", - charon->processor->get_idle_threads(charon->processor), - charon->processor->get_total_threads(charon->processor)); + hydra->processor->get_idle_threads(hydra->processor), + hydra->processor->get_total_threads(hydra->processor)); fprintf(out, " job queue load: %d,", - charon->processor->get_job_load(charon->processor)); + hydra->processor->get_job_load(hydra->processor)); fprintf(out, " scheduled events: %d\n", charon->scheduler->get_job_load(charon->scheduler)); fprintf(out, " loaded plugins: "); diff --git a/src/libcharon/plugins/stroke/stroke_socket.c b/src/libcharon/plugins/stroke/stroke_socket.c index 06a636a7d..891128f73 100644 --- a/src/libcharon/plugins/stroke/stroke_socket.c +++ b/src/libcharon/plugins/stroke/stroke_socket.c @@ -24,10 +24,10 @@ #include #include -#include #include #include #include +#include #include "stroke_config.h" #include "stroke_control.h" @@ -586,7 +586,7 @@ static job_requeue_t receive(private_stroke_socket_t *this) ctx->this = this; job = callback_job_create((callback_job_cb_t)process, ctx, (void*)stroke_job_context_destroy, this->job); - charon->processor->queue_job(charon->processor, (job_t*)job); + hydra->processor->queue_job(hydra->processor, (job_t*)job); return JOB_REQUEUE_FAIR; } @@ -684,7 +684,7 @@ stroke_socket_t *stroke_socket_create() this->job = callback_job_create((callback_job_cb_t)receive, this, NULL, NULL); - charon->processor->queue_job(charon->processor, (job_t*)this->job); + hydra->processor->queue_job(hydra->processor, (job_t*)this->job); return &this->public; } diff --git a/src/libcharon/plugins/uci/uci_control.c b/src/libcharon/plugins/uci/uci_control.c index 3c4928be4..0736ed5fd 100644 --- a/src/libcharon/plugins/uci/uci_control.c +++ b/src/libcharon/plugins/uci/uci_control.c @@ -24,6 +24,7 @@ #include "uci_control.h" +#include #include #include #include @@ -294,7 +295,7 @@ uci_control_t *uci_control_create() { this->job = callback_job_create((callback_job_cb_t)receive, this, NULL, NULL); - charon->processor->queue_job(charon->processor, (job_t*)this->job); + hydra->processor->queue_job(hydra->processor, (job_t*)this->job); } return &this->public; } diff --git a/src/libcharon/processing/jobs/callback_job.c b/src/libcharon/processing/jobs/callback_job.c index 45e49112e..4c9a7fdac 100644 --- a/src/libcharon/processing/jobs/callback_job.c +++ b/src/libcharon/processing/jobs/callback_job.c @@ -18,10 +18,11 @@ #include -#include +#include #include #include #include +#include typedef struct private_callback_job_t private_callback_job_t; @@ -226,7 +227,7 @@ static void execute(private_callback_job_t *this) thread_cancellation_point(); if (requeue) { - charon->processor->queue_job(charon->processor, + hydra->processor->queue_job(hydra->processor, &this->public.job_interface); } thread_cleanup_pop(cleanup); diff --git a/src/libcharon/processing/scheduler.c b/src/libcharon/processing/scheduler.c index 345af502a..85796ba18 100644 --- a/src/libcharon/processing/scheduler.c +++ b/src/libcharon/processing/scheduler.c @@ -19,6 +19,7 @@ #include "scheduler.h" +#include #include #include #include @@ -199,7 +200,7 @@ static job_requeue_t schedule(private_scheduler_t * this) remove_event(this); this->mutex->unlock(this->mutex); DBG2(DBG_JOB, "got event, queuing job for execution"); - charon->processor->queue_job(charon->processor, event->job); + hydra->processor->queue_job(hydra->processor, event->job); free(event); return JOB_REQUEUE_DIRECT; } @@ -351,7 +352,7 @@ scheduler_t * scheduler_create() this->condvar = condvar_create(CONDVAR_TYPE_DEFAULT); this->job = callback_job_create((callback_job_cb_t)schedule, this, NULL, NULL); - charon->processor->queue_job(charon->processor, (job_t*)this->job); + hydra->processor->queue_job(hydra->processor, (job_t*)this->job); return &this->public; } diff --git a/src/libcharon/sa/connect_manager.c b/src/libcharon/sa/connect_manager.c index 8e8e19ba7..fa877150b 100644 --- a/src/libcharon/sa/connect_manager.c +++ b/src/libcharon/sa/connect_manager.c @@ -17,6 +17,7 @@ #include +#include #include #include #include @@ -1222,7 +1223,7 @@ static void finish_checks(private_connect_manager_t *this, check_list_t *checkli initiate_data_t *data = initiate_data_create(checklist, initiated); job_t *job = (job_t*)callback_job_create((callback_job_cb_t)initiate_mediated, data, (callback_job_cleanup_t)initiate_data_destroy, NULL); - charon->processor->queue_job(charon->processor, job); + hydra->processor->queue_job(hydra->processor, job); return; } else @@ -1477,7 +1478,7 @@ static void check_and_initiate(private_connect_manager_t *this, { job_t *job = (job_t*)reinitiate_mediation_job_create(mediation_sa, waiting_sa); - charon->processor->queue_job(charon->processor, job); + hydra->processor->queue_job(hydra->processor, job); } iterator->destroy(iterator); diff --git a/src/libcharon/sa/ike_sa.c b/src/libcharon/sa/ike_sa.c index b1638374d..a7b6cce5f 100644 --- a/src/libcharon/sa/ike_sa.c +++ b/src/libcharon/sa/ike_sa.c @@ -24,8 +24,8 @@ #include "ike_sa.h" #include -#include #include +#include #include #include #include @@ -1163,7 +1163,7 @@ METHOD(ike_sa_t, initiate, status_t, { /* mediated connection, initiate mediation process */ job_t *job = (job_t*)initiate_mediation_job_create(this->ike_sa_id); - charon->processor->queue_job(charon->processor, job); + hydra->processor->queue_job(hydra->processor, job); return SUCCESS; } #endif /* ME */ @@ -1709,7 +1709,7 @@ METHOD(ike_sa_t, set_auth_lifetime, void, { DBG1(DBG_IKE, "received AUTH_LIFETIME of %ds, starting reauthentication", lifetime); - charon->processor->queue_job(charon->processor, + hydra->processor->queue_job(hydra->processor, (job_t*)rekey_ike_sa_job_create(this->ike_sa_id, TRUE)); } else if (this->stats[STAT_REAUTH] == 0 || diff --git a/src/libcharon/sa/mediation_manager.c b/src/libcharon/sa/mediation_manager.c index 035f49053..0efbdc2e9 100644 --- a/src/libcharon/sa/mediation_manager.c +++ b/src/libcharon/sa/mediation_manager.c @@ -15,6 +15,7 @@ #include "mediation_manager.h" +#include #include #include #include @@ -241,7 +242,7 @@ static void update_sa_id(private_mediation_manager_t *this, identification_t *pe (void**)&requester) == SUCCESS) { job_t *job = (job_t*)mediation_callback_job_create(requester, peer_id); - charon->processor->queue_job(charon->processor, job); + hydra->processor->queue_job(hydra->processor, job); requester->destroy(requester); } diff --git a/src/libcharon/sa/tasks/child_rekey.c b/src/libcharon/sa/tasks/child_rekey.c index c87a3ef52..b53bfd470 100644 --- a/src/libcharon/sa/tasks/child_rekey.c +++ b/src/libcharon/sa/tasks/child_rekey.c @@ -16,6 +16,7 @@ #include "child_rekey.h" +#include #include #include #include @@ -299,7 +300,7 @@ static status_t process_i(private_child_rekey_t *this, message_t *message) DBG1(DBG_IKE, "peer seems to not support CHILD_SA rekeying, " "starting reauthentication"); this->child_sa->set_state(this->child_sa, CHILD_INSTALLED); - charon->processor->queue_job(charon->processor, + hydra->processor->queue_job(hydra->processor, (job_t*)rekey_ike_sa_job_create( this->ike_sa->get_id(this->ike_sa), TRUE)); return SUCCESS; diff --git a/src/libcharon/sa/tasks/ike_me.c b/src/libcharon/sa/tasks/ike_me.c index a04bf56ec..1b3771696 100644 --- a/src/libcharon/sa/tasks/ike_me.c +++ b/src/libcharon/sa/tasks/ike_me.c @@ -17,6 +17,7 @@ #include +#include #include #include #include @@ -692,7 +693,7 @@ static status_t build_r_ms(private_ike_me_t *this, message_t *message) job_t *job = (job_t*)mediation_job_create(this->peer_id, this->ike_sa->get_other_id(this->ike_sa), this->connect_id, this->connect_key, this->remote_endpoints, this->response); - charon->processor->queue_job(charon->processor, job); + hydra->processor->queue_job(hydra->processor, job); break; } default: diff --git a/src/libcharon/sa/tasks/ike_rekey.c b/src/libcharon/sa/tasks/ike_rekey.c index ea7782b63..a066adc32 100644 --- a/src/libcharon/sa/tasks/ike_rekey.c +++ b/src/libcharon/sa/tasks/ike_rekey.c @@ -16,6 +16,7 @@ #include "ike_rekey.h" +#include #include #include #include @@ -196,7 +197,7 @@ static status_t process_i(private_ike_rekey_t *this, message_t *message) DBG1(DBG_IKE, "peer seems to not support IKE rekeying, " "starting reauthentication"); this->ike_sa->set_state(this->ike_sa, IKE_ESTABLISHED); - charon->processor->queue_job(charon->processor, + hydra->processor->queue_job(hydra->processor, (job_t*)rekey_ike_sa_job_create( this->ike_sa->get_id(this->ike_sa), TRUE)); return SUCCESS; diff --git a/src/libhydra/processing/processor.c b/src/libhydra/processing/processor.c index 731c9e296..2a44f61e8 100644 --- a/src/libhydra/processing/processor.c +++ b/src/libhydra/processing/processor.c @@ -20,6 +20,7 @@ #include "processor.h" +#include #include #include #include