Fix: S3 load balancing to work properly

Libcurl multi interface requests use shared DNS cache by default. They end up (for this or some other reason) to use only one ip when connection to a host that is using DNS load balancing (multiple ips for one hostname). This problem can be fixed by setting each libcurl easy interface to use a separate DNS cache. This can be done using libcurl share interface.
The deleted objects should also be set to NULL.