this could cause loss of messages. The handling was correct if the
connection broke, but not if there was a problem with statement
execution. The most probable case for such a case would be invalid
sql inside the template, and this is now much easier to diagnose.
There exists a race condition that can lead to a segfault. Thanks
go to vbernetr, who performed the analysis and provided patch, which
I only tweaked a very little bit.
- when converting a number and a string to a common type, both were
actually converted to the other variable's type.
- the value of rsCStrConvertToNumber() was miscalculated.
Signed-off-by: Rainer Gerhards <rgerhards@adiscon.com>
As all the calls to PKG_CHECK_MODULES are conditional, it can happen
that PKG_PROG_PKG_CONFIG is not called (i.e. if you not use
--enable-relp). So we enforce a check for pkg-config by adding it to the
global checks.
rsyslog also works with some 1.x.x versions, but I have not details any longer.
I developed with a v1 version for a while. To be on the save side, I request
2.0.0 (Michael Biebl was even more conservative with 2.4.2 - which he had
at hand - and so I am changing this now).
Remove AC_CHECK_HEADERS([mysql/mysql.h],...) as this was causing pain
for users where the mysql headers are not installed in the system include
directory. It was superfluous anyways, as we check for mysql_config and
set the include path to the correct directory.
Update ommysql.c to use #include <mysql.h>, as mysql_config will set the
include path to /path/to/include/mysql/ so <mysql/mysql.h> would not
work.
Remove errmsg.h include as it is not used.
To unclutter configure.ac and to make it easier re-usable, move the check
for atomic operations into a separate m4 macro file and call the macro
RS_ATOMIC_OPERATIONS (RS for RSyslog)
Use PKG_CHECK_MODULES instead of libgnutls-config to get the compilation
flags (vastly simpler). Set minimum version to 2.4.2, as that is the
oldest version I could test with.
As all the calls to PKG_CHECK_MODULES are conditional, it can happen
that PKG_PROG_PKG_CONFIG is not called (i.e. if you not use
--enable-relp). So we enforce a check for pkg-config by adding it to the
global checks.
pkg-config uses uppercase for its _CFLAGS and _LIBS variable names.
So we follow suit and convert all _cflags and _libs variables to
uppercase for more consistency.
... pointed previously to stunnel-alternative, which now that
we support native TLS is now no longer recommended.
Thanks to Michael Biebl for bringing this to my attention.