Fixing owncloud/core#4301

Adding a CURLOPT_FOLLOWLOCATION for HTTP 301 support (e.g yandex disk uses those)
Merge pull request #4302 from synchrone/master

Fixing owncloud/core#4301