kio_http: fix mimetype determination when URL ends with '/'.
Review Request #127076 - Created Feb. 14, 2016 and submitted
When no Content-Type is sent by the server, we determine mimetype from the URL and the contents. In the switch from KMimeType (which took the fileName of the URL) and QMimeDatabase (which takes the full path), we hit a difference: if the path ends with '/' then QMimeDatabase assumes it's a directory, which isn't the case over HTTP. So remove the trailing slash. This commit introduces a test harness for kio_http: a basic HTTP server running in a separate thread, which I wrote for KDSoap (LGPL).
Unit test + watching kio_http debug output in my current work on keditbookmarks favicon support.
The missing Content-Type is due to another bug, but that's for the next RR.
|replace with category based logging?||Milian Wolff|