diff options
Diffstat (limited to 'proto/wireguard/wireguard.c')
-rw-r--r-- | proto/wireguard/wireguard.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/proto/wireguard/wireguard.c b/proto/wireguard/wireguard.c index 6ac235f7..1837dc9c 100644 --- a/proto/wireguard/wireguard.c +++ b/proto/wireguard/wireguard.c @@ -44,8 +44,10 @@ int get_device(struct wg_proto *p, wg_device **pdev, const char *device_name) wg_generate_public_key(dev->public_key, dev->private_key); } if (c->listen_port) - dev->flags |= WGDEVICE_HAS_LISTEN_PORT; - dev->listen_port = c->listen_port; + { + dev->flags |= WGDEVICE_HAS_LISTEN_PORT; + dev->listen_port = c->listen_port; + } DBG("listen port %d\n", c->listen_port); struct peer_config *pc = NULL; |