diff options
author | Juanli Shen <juanlishen@google.com> | 2018-06-18 15:22:04 -0700 |
---|---|---|
committer | Juanli Shen <juanlishen@google.com> | 2018-06-18 16:20:21 -0700 |
commit | 332b32555cb70f40ed15808d7194dcda7b9f9c00 (patch) | |
tree | 96eeb78d77257b271ae3610035ea351469f40b5b /src/core/lib/iomgr/socket_utils_uv.cc | |
parent | f9035befc6c9b24f7111914d620102e58e80e94f (diff) |
Add endianness conversion for long
Diffstat (limited to 'src/core/lib/iomgr/socket_utils_uv.cc')
-rw-r--r-- | src/core/lib/iomgr/socket_utils_uv.cc | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/core/lib/iomgr/socket_utils_uv.cc b/src/core/lib/iomgr/socket_utils_uv.cc index 7eba40c46b..b5f96b52df 100644 --- a/src/core/lib/iomgr/socket_utils_uv.cc +++ b/src/core/lib/iomgr/socket_utils_uv.cc @@ -33,6 +33,10 @@ uint16_t grpc_htons(uint16_t hostshort) { return htons(hostshort); } uint16_t grpc_ntohs(uint16_t netshort) { return ntohs(netshort); } +uint32_t grpc_htonl(uint32_t hostlong) { return htonl(hostlong); } + +uint32_t grpc_ntohl(uint32_t netlong) { return ntohl(netlong); } + int grpc_inet_pton(int af, const char* src, void* dst) { return inet_pton(af, src, dst); } |