diff options
Diffstat (limited to 'src/openvpn/mudp.c')
-rw-r--r-- | src/openvpn/mudp.c | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/src/openvpn/mudp.c b/src/openvpn/mudp.c index 4f63654..d5459f8 100644 --- a/src/openvpn/mudp.c +++ b/src/openvpn/mudp.c @@ -5,7 +5,7 @@ * packet encryption, packet authentication, and * packet compression. * - * Copyright (C) 2002-2018 OpenVPN Inc <sales@openvpn.net> + * Copyright (C) 2002-2021 OpenVPN Inc <sales@openvpn.net> * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License version 2 @@ -29,11 +29,9 @@ #include "syshead.h" -#if P2MP_SERVER - #include "multi.h" #include <inttypes.h> -#include "forward-inline.h" +#include "forward.h" #include "memdbg.h" @@ -278,7 +276,12 @@ p2mp_iow_flags(const struct multi_context *m) { flags |= IOW_READ; } - +#ifdef _WIN32 + if (tuntap_ring_empty(m->top.c1.tuntap)) + { + flags &= ~IOW_READ_TUN; + } +#endif return flags; } @@ -379,4 +382,3 @@ tunnel_server_udp(struct context *top) tunnel_server_udp_single_threaded(top); } -#endif /* if P2MP_SERVER */ |