Use better compatible Net::HTTP api for older Ruby versions

This improves compatibility with Ruby versions < 2.0 if they are used
to build Rubinius