TSG-18165 Manipulation日志中 Subscriber ID值为空

This commit is contained in:
fengweihao
2023-12-26 17:13:03 +08:00
parent f69de9f4e3
commit 21bbd4e1f7
3 changed files with 18 additions and 6 deletions

View File

@@ -212,6 +212,7 @@ int proxy_send_log(struct proxy_logger* handle, const struct proxy_log* log_msg)
cJSON_AddNumberToObject(common_obj, "end_timestamp_ms", get_time_ms(cur_time));
unsigned int category_id_val[64]={0};
char source_subscribe_id[64]={0};
char opt_val[24]={0}; uint16_t opt_out_size;
struct tfe_cmsg * cmsg = tfe_stream_get0_cmsg(log_msg->stream);
if (cmsg!=NULL)
@@ -221,6 +222,11 @@ int proxy_send_log(struct proxy_logger* handle, const struct proxy_log* log_msg)
{
cJSON_AddStringToObject(common_obj, "session_id", opt_val);
}
ret = tfe_cmsg_get_value(cmsg, TFE_CMSG_SRC_SUB_ID, (unsigned char *)source_subscribe_id, sizeof(source_subscribe_id), &opt_out_size);
if (ret==0)
{
cJSON_AddStringToObject(common_obj, "subscriber_id", source_subscribe_id);
}
ret = proxy_log_get_fqdn_cat(cmsg, category_id_val, sizeof(category_id_val));
if (ret>0)
{