]> git.proxmox.com Git - mirror_corosync.git/commitdiff
totemconfig: change udp netmtu value as a constant
authorliangxin1300 <XLiang@suse.com>
Mon, 15 Mar 2021 06:38:26 +0000 (14:38 +0800)
committerJan Friesse <jfriesse@redhat.com>
Thu, 25 Mar 2021 09:48:47 +0000 (10:48 +0100)
Insted of using "magic number" use UDP_NETMTU constant.

Signed-off-by: liangxin1300 <XLiang@suse.com>
Reviewed-by: Jan Friesse <jfriesse@redhat.com>
exec/totemconfig.c

index f5730fb6f820694cc69eb7109fbf9fad6b5ebc89..b8856073a82e02ef002e1ca5b50c8e43426e4746 100644 (file)
@@ -81,6 +81,8 @@
 #define MAX_MESSAGES                           17
 #define MISS_COUNT_CONST                       5
 #define BLOCK_UNLISTED_IPS                     1
+/* This constant is not used for knet */
+#define UDP_NETMTU                              1500
 
 /* Currently all but PONG_COUNT match the defaults in libknet.h */
 #define KNET_PING_INTERVAL                      1000
@@ -2099,7 +2101,7 @@ int totem_config_validate (
                        totem_config->net_mtu = KNET_MAX_PACKET_SIZE;
                }
                else {
-                       totem_config->net_mtu = 1500;
+                       totem_config->net_mtu = UDP_NETMTU;
                }
        }