joyent/node — pull request #5284 by bnoordhuis (2013-04-12 14:14:45+00:00)
Title: http: escape unsafe characters in request path

Make http.request() and friends escape unsafe characters in the request
path. That is, a request for '/foo bar' is now escaped as '/foo%20bar'.

Before this commit, the path was used as-is in the request status line,
creating an invalid HTTP request ("GET /foo bar HTTP/1.1").

Fixes #4381.