xbmc/xbmc — pull request #2316 by Montellese (2013-02-27 09:27:47+00:00)
Title: webserver: work around a potential crash bug in libmicrohttpd 0.9.x

As observed and investigated by @ulion, libmicrohttpd 0.9.x can cause crashes on specific platforms (e.g. iOS) when using a MHD_USE_SELECT_INTERNALLY in combination with a thread pool (MHD_OPTION_THREAD_POOL_SIZE) because of non- copyable mutex structures (see https://gnunet.org/bugs/view.php?id=2803 for the bug report).

This change uses MHD_USE_SELECT_INTERNALLY in combination with a thread pool for anything below 0.9.x (0x00090B01 specifically) and one thread per connection for anything above that to avoid the bug @ulion uncovered until it has been fixed.

Is this ok like this or do we want to test all platforms and enable/disable thread pooling based on the platform and the libmicrohttpd version being used?