diff --git a/proxy/http/HttpSM.cc b/proxy/http/HttpSM.cc index 52a0e498244..aae29614b1f 100644 --- a/proxy/http/HttpSM.cc +++ b/proxy/http/HttpSM.cc @@ -7694,6 +7694,8 @@ HttpSM::redirect_request(const char *redirect_url, const int redirect_len) // we have a new OS and need to have DNS lookup the new OS t_state.dns_info.lookup_success = false; t_state.force_dns = false; + t_state.server_info.clear(); + t_state.parent_info.clear(); if (t_state.txn_conf->cache_http) { t_state.cache_info.object_read = nullptr; diff --git a/proxy/http/HttpTransact.h b/proxy/http/HttpTransact.h index f47fbcf7bcf..338bcd8cb76 100644 --- a/proxy/http/HttpTransact.h +++ b/proxy/http/HttpTransact.h @@ -637,10 +637,14 @@ class HttpTransact connect_result = e; } - ConnectionAttributes() + ConnectionAttributes() { clear(); } + + void + clear() { - memset(&src_addr, 0, sizeof(src_addr)); - memset(&dst_addr, 0, sizeof(dst_addr)); + ink_zero(src_addr); + ink_zero(dst_addr); + connect_result = 0; } };