🐞 fix(TSG-15212): 修复TFE_CMSG_SSL_INTERCEPT_STATE字段设置错误; 修复msgpack默写字段为空时, 增加默认值
This commit is contained in:
@@ -163,7 +163,7 @@ error_out:
|
||||
struct acceptor_kni_v4 *acceptor_kni_v4_create(struct tfe_proxy *proxy, const char *profile)
|
||||
{
|
||||
void *packet_io_logger = NULL;
|
||||
packet_io_logger = MESA_create_runtime_log_handle("packet_io", RLOG_LV_DEBUG);
|
||||
packet_io_logger = (void *)MESA_create_runtime_log_handle("packet_io", RLOG_LV_DEBUG);
|
||||
assert(packet_io_logger != NULL);
|
||||
|
||||
g_packet_io_logger = packet_io_logger;
|
||||
|
||||
@@ -621,7 +621,7 @@ int main(int argc, char * argv[])
|
||||
/* adds locking, only required if accessed from separate threads */
|
||||
evthread_use_pthreads();
|
||||
|
||||
g_default_logger = MESA_create_runtime_log_handle("tfe", RLOG_LV_DEBUG);
|
||||
g_default_logger = (void *)MESA_create_runtime_log_handle("tfe", RLOG_LV_DEBUG);
|
||||
if (unlikely(g_default_logger == NULL))
|
||||
{
|
||||
TFE_LOG_ERROR(g_default_logger, "Failed at creating default logger: %s", "log/tfe.log");
|
||||
|
||||
@@ -1488,7 +1488,7 @@ static void peek_chello_on_succ(future_result_t * result, void * user)
|
||||
TFE_LOG_ERROR(ctx->mgr->logger, "CertStore is unavailable, PASSTHROUGH");
|
||||
}
|
||||
|
||||
ssl_stream_set_cmsg_integer(s_stream, TFE_CMSG_SSL_INTERCEPT_STATE, s_stream->up_parts.action);
|
||||
ssl_stream_set_cmsg_uint8(s_stream, TFE_CMSG_SSL_INTERCEPT_STATE, s_stream->up_parts.action);
|
||||
ctx->s_stream = s_stream;
|
||||
if(s_stream->up_parts.action==SSL_ACTION_PASSTHROUGH)
|
||||
{
|
||||
|
||||
@@ -1344,7 +1344,7 @@ void __stream_access_log_write(struct tfe_stream_private * stream)
|
||||
"%s/%s/%s ", __str_stream_log_type(ev_log->type), str_dir, ev_log->str_error);
|
||||
}
|
||||
|
||||
MESA_handle_runtime_log(stream->stream_logger, RLOG_LV_INFO, "access",
|
||||
TFE_LOG_INFO(stream->stream_logger, RLOG_LV_INFO, "access",
|
||||
"%d %d %d %s %s %s %s %s %s", stream->log_fd_downstream, stream->log_fd_upstream, stream->keyring_id,
|
||||
stream->str_stream_addr, str_passthrough, str_kill, str_log_event,
|
||||
stream->ssl_downstream_info_dump, stream->ssl_upstream_info_dump);
|
||||
@@ -1889,7 +1889,7 @@ void tfe_stream_write_access_log(const struct tfe_stream * stream, int level, co
|
||||
vasprintf(&__tmp_buffer, fmt, arg_ptr);
|
||||
|
||||
/* Log content with stream tag */
|
||||
MESA_handle_runtime_log(_stream->stream_logger, level, "access", "%s %s", _stream->str_stream_addr, __tmp_buffer);
|
||||
TFE_LOG_INFO(_stream->stream_logger, RLOG_LV_INFO, "access", "%s %s", _stream->str_stream_addr, __tmp_buffer);
|
||||
free(__tmp_buffer);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user