summaryrefslogtreecommitdiffstats
path: root/src/fastd.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/fastd.c')
-rw-r--r--src/fastd.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/fastd.c b/src/fastd.c
index 9194301..149a380 100644
--- a/src/fastd.c
+++ b/src/fastd.c
@@ -116,8 +116,10 @@ static void init_socket(fastd_context *ctx) {
static void init_peers(fastd_context *ctx) {
fastd_peer_config *peer_conf;
- for (peer_conf = ctx->conf->peers; peer_conf; peer_conf = peer_conf->next)
- fastd_peer_add(ctx, peer_conf);
+ for (peer_conf = ctx->conf->peers; peer_conf; peer_conf = peer_conf->next) {
+ if (peer_conf->enabled)
+ fastd_peer_add(ctx, peer_conf);
+ }
}
static void update_time(fastd_context *ctx) {
@@ -393,8 +395,6 @@ int main(int argc, char *argv[]) {
update_time(&ctx);
- conf.protocol->init(&ctx);
-
init_peers(&ctx);
init_tuntap(&ctx);