Passing the remote address to open_socket() would be semantically quite different from providing a local address if the only purpose is to get the adress family and not binding the socket.
I'm not quite sure I follow you. Of course it's different from providing a local address. So?
Anyway, those changes were the minimal needed to get
Protocols.HTTP.get_url("http://%5B::1%5D:1234/something/")
to succeed. Whether Query.pike could be redesigned was beyond the scope of my fix since I needed IPv6 functionality in place yesterday for a customer test.
But they are not sufficient to get
Protocols.HTTP.get_url("http://ipv6.google.com/something/")
to work.
I think it's very bad to commit ad-hoc hacks to the repository without prior discussion at this point in the release cycle. What you do in your working copy is your own business of course.