修复报告处理逻辑

This commit is contained in:
lnk
2026-07-01 14:51:55 +08:00
parent 145092b0ba
commit 405048ed44
10 changed files with 24 additions and 102 deletions

View File

@@ -197,32 +197,14 @@ void closeChannel(chnl_usr_t *chnl_usr)
ALL_RCB_INFO *all_rcb_info;
RCB_INFO *rcb_info;
ST_RET ret;
//lnk20260617防止复用崩溃
/*if(chnl_usr->net_info->user_info)
{
if(chnl_usr->net_info->user_info)
{
all_rcb_info = (ALL_RCB_INFO *)chnl_usr->net_info->user_info;
all_rcb_info = chnl_usr->all_rcb_info;
while((rcb_info = (RCB_INFO *)list_get_first(&all_rcb_info->rcb_info_list)) != NULL)
rcb_info_destroy (rcb_info);
chk_free(all_rcb_info);
chnl_usr->net_info->user_info=NULL;
}*/
if (chnl_usr->all_rcb_info)
{
all_rcb_info = chnl_usr->all_rcb_info;
while ((rcb_info = (RCB_INFO *)list_get_first(&all_rcb_info->rcb_info_list)) != NULL) {
rcb_info_destroy(rcb_info);
}
chk_free(all_rcb_info);
chnl_usr->all_rcb_info = NULL;
}
chnl_usr->net_info->user_info = NULL;
//lnk20260617防止复用崩溃
chnl_usr->net_info->rem_vmd = NULL;
echo_warn("---------start disconnectFromServer!\n");
ret = mms_disconnectFromServer(chnl_usr->net_info,&chnl_usr->m_reqCtrl);
@@ -237,10 +219,7 @@ void closeChannel(chnl_usr_t *chnl_usr)
mvl_free_req_ctrl(chnl_usr->m_reqCtrl);
//lnk20260617防止复用崩溃
chnl_usr->all_rcb_info = NULL;
chnl_usr->net_info->user_info = NULL;
chnl_usr->net_info->user_ext = NULL;
chnl_usr->net_info = NULL;
@@ -267,7 +246,7 @@ ST_VOID Callback_channel_disconnect_ind(MVL_NET_INFO * NetInfo, ST_INT discType)
{
chnl_usr_t *chnl_usr;
chnl_usr = (chnl_usr_t*)NetInfo->user_info;
chnl_usr = (chnl_usr_t*)NetInfo->user_ext;
if ( chnl_usr ) {
if(chnl_usr->m_state == CHANNEL_CONNECTING)
@@ -286,7 +265,7 @@ ST_VOID Callback_channel_disconnect_ind(MVL_NET_INFO * NetInfo, ST_INT discType)
chnl_usr->net_info = NULL;
NetInfo->user_info = NULL;
NetInfo->user_ext = NULL;
}
printf(" Callback_channel_disconnect_ind ,NetInfo = %x",NetInfo);
@@ -1741,7 +1720,7 @@ void CheckNextNotConnectedChannel()
chnl_usr->m_reqCtrl = NULL;
chnl_usr->m_state = CHANNEL_CONNECTED;
chnl_usr->net_info->user_info = chnl_usr;
chnl_usr->net_info->user_ext = chnl_usr;
all_rcb_info = (ALL_RCB_INFO *)chk_calloc(1, sizeof (ALL_RCB_INFO));
all_rcb_info->rpt_typeids = &g_rpt_typeids;
@@ -1750,9 +1729,7 @@ void CheckNextNotConnectedChannel()
echo_warn("chnl_usr->net_info->user_info is not NULL\n");
}
//lnk20260617防止复用崩溃
//chnl_usr->net_info->user_info = all_rcb_info;
chnl_usr->net_info->user_info = all_rcb_info;
chnl_usr->chnl->ied->status = STATUS_NORMAL;
chnl_usr->chnl->status = STATUS_NORMAL;
@@ -1903,7 +1880,7 @@ void CheckNextNotConnectedChannel()
echo_warn3( "CHANNEL_DISCONNECTING done %s:%d,NetInfo= %x ",chnl_usr->ip_str,chnl_usr->chnl->port,chnl_usr->net_info);
mvl_free_req_ctrl(chnl_usr->m_reqCtrl);
if(chnl_usr->net_info)
chnl_usr->net_info->user_info = NULL;
chnl_usr->net_info->user_ext = NULL;
chnl_usr->m_reqCtrl = NULL;
chnl_usr->net_info = NULL;
@@ -1931,7 +1908,7 @@ void CheckNextNotConnectedChannel()
echo_warn2( "CHANNEL_DISCONNECTING reqCtrl->done未完成,but time over 180 secs, close channel IP %s,NetInfo= %x ",chnl_usr->ip_str,chnl_usr->net_info);
mvl_free_req_ctrl(chnl_usr->m_reqCtrl);
chnl_usr->net_info->user_info = NULL;
chnl_usr->net_info->user_ext = NULL;
mms_release_connection(chnl_usr->net_info);
chnl_usr->net_info->rem_vmd = NULL;