contrib/reindent.pl: allow explicit mode spec on the command line
Merge pull request #1542 from jimis/minor

Do not truncate even the longest debug output
body server control: allowlegacyconnects

Which IPs or subnets to allow connections from, even though they are not
using the latest protocol.
Stylistic changes.
Fix old protocol client_code segfault.

Also reverted opaqueness of ConnectionInfo and restored direct access to
it for the relevant client_code. I expect that at least for libcfnet
internal usage I don't have to deal with abstraction layers.
Silence warning when compiling without XML.
Moving documentation in .c files from header files.

This is documentation the programmer has to see the moment he looks up
the function name, and currently most (all?) editors take you to the
implementation, not the declaration.
Demoted cf-serverd client-triggered errors from LOG_LEVEL_ERR to NOTICE.
body common control: protocol_version
Define CF_PROTOCOL_LATEST same as CF_PROTOCOL_TLS.

Also make the code a bit more future-proof, if more than one protocols
ever exist inside the TLS layer.
Applied review corrections to Changelog.
Moved CFENGINE_PORT to libcfnet.
Implemented cf-runagent common control protocol_version.

Also removed a couple of unrelated verbose comments.
readtcp() and selectservers()...

...updated and cleaned-up to use the new libcfnet API, SocketConnect()
in particular. Automagically they were given the option of specifying
the port number as service string.
Do not SendTransaction() before determining the protocol being used.

This fixes part of redmine #4736.

Also changed the apoptosis message to LOG_LEVEL_CRIT from
LOG_LEVEL_ERR. Makes sense since the server is dying anyway...
Parse common control protocol_version only if copy_from protocol_version is undefined.
Make it clear in the code that "allowlegacyconnects" ...

... allows every protocol except the latest one. In other words, if
allowlegacyconnects is empty, only CF_PROTOCOL_LATEST is allowed.
Typo.
Close socket descriptor if bind() fails.
In client code, CF_PROTOCOL_UNDEFINED means classic protocol instead of latest.