RM3979: reworked a test to use putenv() instead of setenv().
Cleanup OpenSSL locking functions.
Error checking mutexes for OpenSSL.
Introduced proper checking and logging of our locking primitives.

ThreadLock(), ThreadUnlock() should now be preferred against
native pthread_mutex_lock().
Use error checking mutexes for our dbm API.
Redmine#5339: add packageupdatesmatching function
It was being checked as a bool but was returning int.
Merge pull request #1617 from jimis/varfix2

It was being checked as a bool but was returning int.
Assert we're not leaking memory

As suggested by @kacfengine.
Log errors properly for failing pthread operations

As suggested by @kacfengine.
Merge pull request #1611 from jimis/agent_protocol_version

Error checking mutexes and detection of errors.
Added logging.c as a source to libdb.la in tests/unit

Because all mutex locking/unlocking now require Log(). This caused a
bunch of changes like renaming libdb.la intermediate objects (by
redefining libdb_la_CPPFLAGS) and removing lots of logging stubs from
various tests.
Fix db_load test double symbols during linking.
Merge pull request #1620 from jimis/agent_protocol_version

Added logging.c as a source to libdb.la in tests/unit
Merge pull request #1612 from ediosyncratic/setenv-purge

RM3979: reworked a test to use putenv() instead of setenv().
Let serverd tests use standard framework so that test_* metas work.
Merge pull request #1614 from tzz/redmine5339-packageupdatesmatching

Redmine#5339: add packageupdatesmatching function