]> The Tcpdump Group git mirrors - tcpdump/commit
Fix compiling on GNU/Hurd. [skip appveyor]
authorDenis Ovsienko <[email protected]>
Sun, 4 Feb 2024 15:31:19 +0000 (15:31 +0000)
committerDenis Ovsienko <[email protected]>
Sun, 4 Feb 2024 15:43:34 +0000 (15:43 +0000)
commit6cf3ea7d0f7c43440f74c93b95a7864f30fc68b4
tree2d32381e68977051515ab9f1a502abc71f609123
parentec780ab24acf7fc52eb40cfbf21c0ec51240c666
Fix compiling on GNU/Hurd. [skip appveyor]

GNU/Hurd does not define MAXHOSTNAMELEN because it does not define
HOST_NAME_MAX, even if __USE_POSIX is defined.  This causes the
following:

./print-bgp.c:1997:14: error: 'MAXHOSTNAMELEN' undeclared (first use in
  this function)
./print-bgp.c:2965:14: error: 'MAXHOSTNAMELEN' undeclared (first use in
  this function)
./print-icmp.c:502:11: error: 'MAXHOSTNAMELEN' undeclared (first use in
  this function)

However, the above code should not depend on this OS-specific detail to
size its temporary printing buffers, so just hard-code the sizes.
CHANGES
README.md
print-bgp.c
print-icmp.c