m_ssl_openssl Clear the error queue before every SSL_* call
m_ssl_openssl Enable single (EC)DH use and disable SSL v2

Options enabled:
- SSL_OP_NO_SSLv2
- SSL_OP_SINGLE_DH_USE
- SSL_OP_SINGLE_ECDH_USE (if it exists)

Partial backport of #856 by @jvehent
m_ssl_openssl Disable session caching and session tickets
m_ssl_openssl Allow configuring raw OpenSSL context options
Fix various warnings when building with LLVM 3.5.

- warning: absolute value function 'abs' given an argument of type 'long' but has parameter of type 'int' which may cause truncation of value [-Wabsolute-value]
- warning: 'this' pointer cannot be null in well-defined C++ code; pointer may be assumed to always convert to true [-Wundefined-bool-conversion]
Avoid calling methods on NULL pointers wherever possible.

The trick we use to allow this is undefined behaviour and is not
liked by LLVM. We should stop using it but it has the potential to
break to many things for a minor release.
Merge pull request #933 from SaberUK/insp20+fix-llvm34

Fix various warnings when building with LLVM 3.5.
Replace dodgy use of const char* and memcpy with std::string.

This was backported from commit e01df63 in master.
Kill some logically dead code detected by Coverity.

- m_watch: wl has already been confirmed to not be NULL on L161.
Merge pull request #934 from SaberUK/insp20+fix-various-issues

Fix various issues detected by Coverity.
m_nationalchars Rebuild core hashmaps when the national_case_insensitive_map changes

Issue #923
m_nationalchars Rebuild the hash map in m_watch when the national_case_insensitive_map changes

Issue #923
m_spanningtree Rebuild serverlist and sidlist when receiving a specific Request

Issue #923
m_nationalchars Ask m_spanningtree to rebuild its hashmaps when the national_case_insensitive_map changes

Issue #923
Add a workaround for compiling modules with Windows line endings.
m_ssl_openssl Add user-friendly config options for setting a few OpenSSL context options
m_ssl_openssl Return an error from the IOHook read and write functions if the handshake returns 0

The meaning of a 0 return value quoted from the manual:
The TLS/SSL handshake was not successful but was shut down controlled and by the specifications of the TLS/SSL protocol.
Merge pull request #935 from SaberUK/insp20+fix-crlf

Add a workaround for compiling modules with Windows line endings.
m_ssl_openssl Remove bogus errno assignment from CloseSession()
m_ssl_openssl Free the ssl_cert object as soon as the session is closed instead of waiting for the next VerifyCertificate() or new connection