Page MenuHomePhabricator

[lldb] [Process/gdb-remote] Use '127.0.0.1' in ConnectLocally()
ClosedPublic

Authored by mgorny on Mar 2 2019, 11:38 PM.

Details

Summary

Use '127.0.0.1' instead of 'localhost' in ConnectLocally() function
as this is the specific address the server is bound to. Using
'localhost' may involve trying IPv6 first which may accidentally be used
by another service.

While technically it might be interesting to support IPv6 here, it would
need to be supported properly, with the connection copying family
and address from the listening socket, and possibly without relying
on existence of 'localhost' at all.

Diff Detail

Repository
rL LLVM

Event Timeline

mgorny created this revision.Mar 2 2019, 11:38 PM
Herald added a project: Restricted Project. · View Herald TranscriptMar 2 2019, 11:38 PM
Herald added a subscriber: abidh. · View Herald Transcript
labath accepted this revision.Mar 3 2019, 4:36 AM
This revision is now accepted and ready to land.Mar 3 2019, 4:36 AM
This revision was automatically updated to reflect the committed changes.
Herald added a project: Restricted Project. · View Herald TranscriptMar 3 2019, 4:44 AM