MCPcopy Create free account
hub / github.com/Tencent/phxsql / GetIP

Method GetIP

phxcomm/utils/phx_utils.cpp:29–33  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

27namespace phxsql {
28
29string Utils::GetIP(const uint32_t &svrid) {
30 char tmp[128] = { 0 };
31 sprintf(tmp, "%u.%u.%u.%u", (svrid >> 24) & 0xff, (svrid >> 16) & 0xff, (svrid >> 8) & 0xff, svrid & 0xff);
32 return tmp;
33}
34
35uint32_t Utils::GetSvrID(const string &ip) {
36 uint32_t svrid = 0;

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected