This is an archive of the discontinued LLVM Phabricator instance.

[NFC] Adding a new wrapper for getaddrinfo
ClosedPublic

Authored by beanz on Apr 7 2017, 11:55 AM.

Details

Summary

This patch adds a new wrapper for getaddrinfo which returns a std::vector of SocketAddresses. While this patch doesn't add any uses of the new function, I have two separable patches that are dependent on this, so I put it in its own patch.

Diff Detail

Repository
rL LLVM

Event Timeline

beanz created this revision.Apr 7 2017, 11:55 AM
zturner accepted this revision.Apr 11 2017, 9:11 AM
zturner added inline comments.
include/lldb/Host/SocketAddress.h
44–45 ↗(On Diff #94550)

What about using Twine here instead of const char * literals?

source/Host/common/SocketAddress.cpp
260 ↗(On Diff #94550)

How about emplace_back(service_ptr)

This revision is now accepted and ready to land.Apr 11 2017, 9:11 AM
beanz added inline comments.Apr 12 2017, 2:07 PM
include/lldb/Host/SocketAddress.h
44–45 ↗(On Diff #94550)

I don't want to use Twine for this because in other patches I'm pulling this into debugserver which doesn't have any dependency on LLVM.

This revision was automatically updated to reflect the committed changes.