|
32 | 32 | break; \ |
33 | 33 | h2o_socket_t *sock_ = (_sock); \ |
34 | 34 | ptls_log_conn_state_t *conn_state = h2o_socket_log_state(sock_); \ |
35 | | - active &= ptls_log_conn_maybe_active(conn_state, (const char *(*)(void *))h2o_socket_get_ssl_server_name, sock_); \ |
| 35 | + active &= ptls_log_conn_maybe_active(conn_state, ptls_log_getsni_h2o_sock(sock_)); \ |
36 | 36 | if (PTLS_LIKELY(active == 0)) \ |
37 | 37 | break; \ |
38 | | - PTLS_LOG__DO_LOG(h2o, _name, conn_state, (const char *(*)(void *))h2o_socket_get_ssl_server_name, sock_, 1, { \ |
| 38 | + PTLS_LOG__DO_LOG(h2o, _name, conn_state, ptls_log_getsni_h2o_sock(sock_), 1, { \ |
39 | 39 | PTLS_LOG_ELEMENT_PTR(sock, sock_); \ |
40 | 40 | do { \ |
41 | 41 | _block \ |
|
50 | 50 | break; \ |
51 | 51 | h2o_conn_t *conn_ = (_conn); \ |
52 | 52 | ptls_log_conn_state_t *conn_state = conn_->callbacks->log_state(conn_); \ |
53 | | - active &= ptls_log_conn_maybe_active(conn_state, (const char *(*)(void *))conn_->callbacks->get_ssl_server_name, conn_); \ |
| 53 | + active &= ptls_log_conn_maybe_active(conn_state, ptls_log_getsni_h2o_conn(conn_)); \ |
54 | 54 | if (active == 0) \ |
55 | 55 | break; \ |
56 | | - PTLS_LOG__DO_LOG(h2o, _name, conn_state, (const char *(*)(void *))conn_->callbacks->get_ssl_server_name, conn_, 1, { \ |
| 56 | + PTLS_LOG__DO_LOG(h2o, _name, conn_state, ptls_log_getsni_h2o_conn(conn_), 1, { \ |
57 | 57 | PTLS_LOG_ELEMENT_UNSIGNED(conn_id, conn_->id); \ |
58 | 58 | do { \ |
59 | 59 | _block \ |
@@ -174,8 +174,7 @@ static inline void h2o_probe_log_request(h2o_req_t *req, uint64_t req_index) |
174 | 174 | if (H2O_PROBE_IS_ENABLED(RECEIVE_REQUEST_HEADER) || |
175 | 175 | (ptls_log_point_maybe_active(&receive_request_header_logpoint) != 0 && |
176 | 176 | (receive_request_header_logpoint.state.active_conns & |
177 | | - ptls_log_conn_maybe_active(req->conn->callbacks->log_state(req->conn), |
178 | | - (const char *(*)(void *))req->conn->callbacks->get_ssl_server_name, req->conn)) != 0)) { |
| 177 | + ptls_log_conn_maybe_active(req->conn->callbacks->log_state(req->conn), ptls_log_getsni_h2o_conn(req->conn))) != 0)) { |
179 | 178 | if (req->input.authority.base != NULL) |
180 | 179 | h2o_probe_request_header(req, req_index, H2O_TOKEN_AUTHORITY->buf, req->input.authority); |
181 | 180 | if (req->input.method.base != NULL) |
@@ -203,8 +202,7 @@ static inline void h2o_probe_log_response(h2o_req_t *req, uint64_t req_index) |
203 | 202 | if (H2O_PROBE_IS_ENABLED(SEND_RESPONSE_HEADER) || |
204 | 203 | (ptls_log_point_maybe_active(&send_response_header_logpoint) != 0 && |
205 | 204 | (send_response_header_logpoint.state.active_conns & |
206 | | - ptls_log_conn_maybe_active(req->conn->callbacks->log_state(req->conn), |
207 | | - (const char *(*)(void *))req->conn->callbacks->get_ssl_server_name, req->conn)) != 0)) { |
| 205 | + ptls_log_conn_maybe_active(req->conn->callbacks->log_state(req->conn), ptls_log_getsni_h2o_conn(req->conn))) != 0)) { |
208 | 206 | if (req->res.content_length != SIZE_MAX) { |
209 | 207 | char buf[sizeof(H2O_SIZE_T_LONGEST_STR)]; |
210 | 208 | size_t len = (size_t)sprintf(buf, "%zu", req->res.content_length); |
|
0 commit comments