Merge pull request #536 from SaberUK/master+fix-kqueue-test

Fix kqueue test on non-Apple BSDs.
Fix the poll socket engine.
Merge pull request #537 from SaberUK/master+fix-poll

Fix the poll socket engine.
Fix GCC warnings about using C++11 features when not in C++11 mode.
Merge pull request #538 from SaberUK/master+silence-gcc

Fix GCC warnings about using C++11 features when not in C++11 mode.
Fix padding bug in GenerateSID(), spotted by @ShutterQuick
Added a function to replace all the ugly sprintf-ing everywhere
Purge the old chanlog code from the module file.
Merge pull request #541 from SaberUK/master+chanlog

Purge the old chanlog code from the module file.
Added macro to allow simpler logic in functions with the need to vsnprintf
Replaced vsnprintf with VAFORMAT in users.cpp
Replaced vsnprintf with VAFORMAT in channels.cpp
Updated SendWhoisLine in helperfucks.cpp to use VAFORMAT instead of vsnprintf
Replaced vsnprintf in snomask.cpp with VAFORMAT
Replaced vsnprintf in logger.cpp with VAFORMAT
Replaced vsnprintf with VAFORMAT in usermanager.cpp
Replaced vsnprintf with VAFORMAT in m_spannintree/main.cpp