pipes.c: use brackets in one-line statements

A matter of coding style, only. The compact form:
   if (something)
       do_st();
is not compliant to this project's coding guidelines.
pipes.c: initialize "CHILDREN" array after realloc()ing it

We avoid spurious errors at close_children() this way.

https://github.com/xrg/cfengine-core/commit/2e02479f59a2c89c91f618522d4334133f7ef485#commitcomment-2303571
Fix build for netbsd + remove unnecessary #if define in SelectBSDMatch
(cherry picked from commit 230728b94fbf0eb5ad26aed9e07be6539ebb7f7b)

Conflicts:

	src/files_select.c
Silence compiler warning.

Variable was unused.
(cherry picked from commit da8ea6811fe2575eca62ceb2691728df8ad04691)
d_type is not standardised, even on Linux. DT_UNKNOWN has been observed on SLES 12.2 with reiserfs. OTRS #2012121510000015

(cherry picked from commit 9255a0692803820ba23cbc18f7fb8ac1c6b8c72f)
Do not canonify values specified in abortbundleclasses/abortclasses - regex is allowed for these. Redmine #1786
(cherry picked from commit 24a84716d50376ad142b95eb6985fd554649311d)
select() does not work for pipes on Windows. Fixes #1908
(cherry picked from commit 2272c19b73fcdf7c5b8e11389ef7af8bbed7c5b7)
Fix incorrect buffer size calculation

This was discovered on OpenBSD which is far more aggressive about
using canaries and placing buffers at memory boundaries. In particular
this most often bites when a scalar is of length 0 because, unlike
Linux and MacOS X, OpenBSD does not return a memory pointer just
before a pre-zeroed section of accessible memory. Therefore any read
or write accesses to the returned pointer will typically result in a
segmenetation fault on that platform.
Update tests for OpenBSD

This will allow all acceptance tests on OpenBSD to pass except for
00_basics/03_bodies/118.cf which is due to a bug in OpenBSD's
implementation of grep. When OpenBSD's grep is corrected or replaced
with GNU grep, that test also passes.
create symlinks instead of copying binaries around
(cherry picked from commit 4fe0cf2aadb6294183c0f4ac5dd46094eb968555)
I missed to add cf-monitord along #1930
(cherry picked from commit 26e27fdc6a89128692a063d128e4cb342637ca2b)
rename failsafe to update #1936
(cherry picked from commit 84814eab02e225719bf22959d2b05b3cf353af99)
Merge pull request #278 from jeramey/3.4.x

OpenBSD support in 3.4.x
ChangeLog updates
Do not return a value from a void function. Redmine #1901
(cherry picked from commit 96c2269e6791f84a99c8af481daf9bf77ec6dc57)
Remove deprecated functions: ToUpperStr, ToLowerStr
(cherry picked from commit 13128ea9b94ea0fd5b8af74ba5cad1420df6064a)
Bug fixed in src/generic_agent.c. Instead freport_text should have been freport_html in function called: ReportContext *OpenCompilationReportFiles(const char *fname)

    Redmine issue: 1931
(cherry picked from commit c65b516a890c20daecc42818c6a4f488db706bb3)
ChangeLog update
Eliminate spurious type-pun warning during HP-UX GCC build.

While the "fd_set" type is defined in /usr/include/sys/_fd_macros.h as a
struct of an array of "long" values in accordance with the XPG4 standard's
requirements, the macros for the FD operations "pretend it is an array of
int32_t's so the binary layout is the same for both Narrow and Wide
processes," as described in _fd_macros.h. In the FD_SET, FD_CLR, and
FD_ISSET macros at line 101, the result is cast to an "__fd_mask *" type,
which is defined as int32_t at _fd_macros.h:82.

This conflict between the "long fds_bits[]" array in the XPG4-compliant
fd_set structure, and the cast to an int32_t - not long - pointer in the
macros, causes a type-pun warning if -Wstrict-aliasing is enabled.
The warning is merely a side effect of HP-UX working as designed,
so it can be ignored.
(cherry picked from commit c35aad25e1fa443487c9fe1b35a7b3695f1886b0)
ChangeLog update