Fix issue with some versions of cURL which don't handle URL fragments correctly