rt: get rid of unused helpers for AF_INET and add bool-based ones, instead

This commit is contained in:
Jeff Olson 2012-06-26 09:05:02 -07:00 committed by Brian Anderson
parent 5014a2a413
commit 8794815da9
2 changed files with 6 additions and 12 deletions

View File

@ -324,18 +324,10 @@ extern "C" size_t
rust_uv_helper_addrinfo_size() {
return sizeof(addrinfo);
}
extern "C" unsigned long int
extern "C" unsigned int
rust_uv_helper_get_INADDR_NONE() {
return INADDR_NONE;
}
extern "C" unsigned long int
rust_uv_helper_get_AF_INET() {
return AF_INET;
}
extern "C" unsigned long int
rust_uv_helper_get_AF_INET6() {
return AF_INET6;
}
extern "C" uv_stream_t*
rust_uv_get_stream_handle_from_connect_req(uv_connect_t* connect) {
@ -518,9 +510,12 @@ rust_uv_freeaddrinfo(addrinfo* res) {
}
extern "C" bool
rust_uv_is_ipv4_addrinfo(addrinfo* input) {
// if it aint AF_INET, it's AF_INET6
return input->ai_family == AF_INET;
}
extern "C" bool
rust_uv_is_ipv6_addrinfo(addrinfo* input) {
return input->ai_family == AF_INET6;
}
extern "C" addrinfo*
rust_uv_get_next_addrinfo(addrinfo* input) {
return input->ai_next;

View File

@ -124,6 +124,7 @@ rust_uv_read_stop
rust_uv_malloc_buf_base_of
rust_uv_free_base_of_buf
rust_uv_is_ipv4_addrinfo
rust_uv_is_ipv6_addrinfo
rust_uv_get_next_addrinfo
rust_uv_addrinfo_as_sockaddr_in
rust_uv_addrinfo_as_sockaddr_in6
@ -138,8 +139,6 @@ rust_uv_helper_addr_in_size
rust_uv_helper_addrinfo_size
rust_uv_helper_uv_getaddrinfo_t_size
rust_uv_helper_get_INADDR_NONE
rust_uv_helper_get_AF_INET
rust_uv_helper_get_AF_INET6
rust_uv_helper_uv_async_t_size
rust_uv_helper_uv_timer_t_size
rust_uv_get_stream_handle_from_connect_req