[pgpool-hackers: 3904] Re: max hostname length in Pgpool-II

Tatsuo Ishii ishii at sraoss.co.jp
Tue May 25 09:53:35 JST 2021


> Pgpool-II has two definitions of max hostname length:
> 
> src/include/pcp/libpcp_ext.h:
> #define MAX_DB_HOST_NAMELEN	 128
> 
> src/include/pool_config.h:
> #define WD_MAX_HOST_NAMELEN (128)
> 
> First question is, why we have the hostname length definition in two
> places. Probably we should unify them into single definition.
> 
> Besides this, 128 seems to be inappropriate. According the wiki page:
> 
> https://en.wikipedia.org/wiki/Hostname
> 
> Max hostname length is 253, rather than 128. If we account the null
> terminator, that will be 254.
> 
> Comments?

Attached is a patch to fix this. If there's no objection, I will
commit/push.

Best regards,
--
Tatsuo Ishii
SRA OSS, Inc. Japan
English: http://www.sraoss.co.jp/index_en.php
Japanese:http://www.sraoss.co.jp
-------------- next part --------------
A non-text attachment was scrubbed...
Name: maxhostnamelen.diff
Type: text/x-patch
Size: 1958 bytes
Desc: not available
URL: <http://www.pgpool.net/pipermail/pgpool-hackers/attachments/20210525/f375b7c9/attachment.bin>


More information about the pgpool-hackers mailing list