diff options
author | Eliot Horowitz <eliot@10gen.com> | 2012-12-10 15:18:51 -0500 |
---|---|---|
committer | Eliot Horowitz <eliot@10gen.com> | 2012-12-10 15:18:51 -0500 |
commit | e7069c1c980a0465ef64dd108a78346a037dd81e (patch) | |
tree | b9eda119bd8a7df076e16e9ce681e1ee3f9452bf /src/mongo/db/commands/isself.cpp | |
parent | c1e12bcce00c771cbecbda33a22f41249ad0d6f2 (diff) | |
download | mongo-e7069c1c980a0465ef64dd108a78346a037dd81e.tar.gz |
SERVER-7886 - use StringData methods, now .data()
Diffstat (limited to 'src/mongo/db/commands/isself.cpp')
-rw-r--r-- | src/mongo/db/commands/isself.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/mongo/db/commands/isself.cpp b/src/mongo/db/commands/isself.cpp index d05ee2a7a12..fcca300f7e3 100644 --- a/src/mongo/db/commands/isself.cpp +++ b/src/mongo/db/commands/isself.cpp @@ -108,7 +108,7 @@ namespace mongo { return out; } - vector<string> getAllIPs(StringData iporhost) { + vector<string> getAllIPs(const string& iporhost) { addrinfo* addrs = NULL; addrinfo hints; memset(&hints, 0, sizeof(addrinfo)); @@ -119,9 +119,9 @@ namespace mongo { vector<string> out; - int ret = getaddrinfo(iporhost.data(), portNum.c_str(), &hints, &addrs); + int ret = getaddrinfo(iporhost.c_str(), portNum.c_str(), &hints, &addrs); if ( ret ) { - warning() << "getaddrinfo(\"" << iporhost.data() << "\") failed: " << gai_strerror(ret) << endl; + warning() << "getaddrinfo(\"" << iporhost << "\") failed: " << gai_strerror(ret) << endl; return out; } |