Allow retry in http connection to remote webdriver

[#6690 phantomjs with selenium 2.38.1 fails with BadStatusLine exception](https://code.google.com/p/selenium/issues/detail?id=6690)

PhantomJS+GhostDriver as of PhantomJS version 1.9.2 does not enable http keep-alive which results in failure to communicate with the webdriver after the first request.

Other implementations of webdriver servers may also close the connection after a timeout - in which case a retry will ensure that the next command doesn't fail.