From: Michael Tokarev Date: Sat, 28 Feb 2009 13:37:51 +0000 (+0300) Subject: Enable PMTUDiscovery only if BOTH sides wants it. X-Git-Tag: release-1.0.10~84 X-Git-Url: https://git.librecmc.org/?p=oweals%2Ftinc.git;a=commitdiff_plain;h=76a1bcaffcf1f1abf81fdda379b703a004640cb4 Enable PMTUDiscovery only if BOTH sides wants it. Don't enable PMTUDiscovery if at least one side does not support it. Before it was enabled if at least one side supported it, now both are required. --- diff --git a/src/protocol_auth.c b/src/protocol_auth.c index cafe45c..9288ec7 100644 --- a/src/protocol_auth.c +++ b/src/protocol_auth.c @@ -483,7 +483,7 @@ bool send_ack(connection_t *c) if((get_config_bool(lookup_config(c->config_tree, "TCPOnly"), &choice) && choice) || myself->options & OPTION_TCPONLY) c->options |= OPTION_TCPONLY | OPTION_INDIRECT; - if((!get_config_bool(lookup_config(c->config_tree, "PMTUDiscovery"), &choice) || choice) || myself->options & OPTION_PMTU_DISCOVERY) + if((!get_config_bool(lookup_config(c->config_tree, "PMTUDiscovery"), &choice) || choice) && (myself->options & OPTION_PMTU_DISCOVERY)) c->options |= OPTION_PMTU_DISCOVERY; get_config_int(lookup_config(c->config_tree, "Weight"), &c->estimated_weight);