mirror of
http://git.haproxy.org/git/haproxy.git/
synced 2024-12-15 07:54:33 +00:00
MINOR: config: extend the default max hostname length to 64 and beyond
Some users reported that the default max hostname length of 32 is too short in some environments. This patch does two things : - it relies on the system's max hostname length as found in MAXHOSTNAMELEN if it is set. This is the most logical thing to do as the system libs generally present the appropriate value supported by the system. This value is 64 on Linux and 256 on Solaris, to give a few examples. - otherwise it defaults to 64 It is still possible to override this value by defining MAX_HOSTNAME_LEN at build time. After some observation time, this patch may be backported to 1.5 if it does not cause any build issue, as it is harmless and may help some users.
This commit is contained in:
parent
7c1c217426
commit
75abcb3106
@ -210,8 +210,12 @@
|
||||
|
||||
/* Maximum host name length */
|
||||
#ifndef MAX_HOSTNAME_LEN
|
||||
#define MAX_HOSTNAME_LEN 32
|
||||
#endif
|
||||
#if MAXHOSTNAMELEN
|
||||
#define MAX_HOSTNAME_LEN MAXHOSTNAMELEN
|
||||
#else
|
||||
#define MAX_HOSTNAME_LEN 64
|
||||
#endif // MAXHOSTNAMELEN
|
||||
#endif // MAX_HOSTNAME_LEN
|
||||
|
||||
/* Maximum health check description length */
|
||||
#ifndef HCHK_DESC_LEN
|
||||
|
Loading…
Reference in New Issue
Block a user