Skip to content
Snippets Groups Projects
Commit 8186a9c5 authored by dmitriy.gerasimov's avatar dmitriy.gerasimov
Browse files

Merge branch 'feature-2631' into 'master'

partially fixed bug with error message: !! dap_CLIENT_STAGE_STATUS_DONE

See merge request !9
parents 1ae33a38 552be75c
No related branches found
No related tags found
1 merge request!9partially fixed bug with error message: !! dap_CLIENT_STAGE_STATUS_DONE
...@@ -84,6 +84,7 @@ typedef void (*dap_client_callback_data_size_t) (dap_client_t *, void *, size_t) ...@@ -84,6 +84,7 @@ typedef void (*dap_client_callback_data_size_t) (dap_client_t *, void *, size_t)
#define DAP_UPLINK_PATH_STREAM_CTL "stream_ctl" //"091348758013553" #define DAP_UPLINK_PATH_STREAM_CTL "stream_ctl" //"091348758013553"
#define DAP_UPLINK_PATH_STREAM "stream" //"874751843144" #define DAP_UPLINK_PATH_STREAM "stream" //"874751843144"
#define DAP_UPLINK_PATH_LICENSE "license" #define DAP_UPLINK_PATH_LICENSE "license"
//#define DAP_UPLINK_PATH_NODE_LIST "nodelist"
#define DAP_UPLINK_PATH_SERVER_LIST "slist" #define DAP_UPLINK_PATH_SERVER_LIST "slist"
#ifdef __cplusplus #ifdef __cplusplus
......
...@@ -382,7 +382,6 @@ static void s_stage_status_after(dap_client_pvt_t * a_client_pvt) ...@@ -382,7 +382,6 @@ static void s_stage_status_after(dap_client_pvt_t * a_client_pvt)
case STAGE_STATUS_DONE: { case STAGE_STATUS_DONE: {
log_it(L_INFO, "Stage status %s is done", log_it(L_INFO, "Stage status %s is done",
dap_client_stage_str(a_client_pvt->stage)); dap_client_stage_str(a_client_pvt->stage));
bool l_is_last_stage = (a_client_pvt->stage == a_client_pvt->stage_target);
if(a_client_pvt->stage_status_done_callback) { if(a_client_pvt->stage_status_done_callback) {
a_client_pvt->stage_status_done_callback(a_client_pvt->client, NULL); a_client_pvt->stage_status_done_callback(a_client_pvt->client, NULL);
// Expecting that its one-shot callback // Expecting that its one-shot callback
...@@ -390,6 +389,7 @@ static void s_stage_status_after(dap_client_pvt_t * a_client_pvt) ...@@ -390,6 +389,7 @@ static void s_stage_status_after(dap_client_pvt_t * a_client_pvt)
} else } else
log_it(L_WARNING, "Stage done callback is not present"); log_it(L_WARNING, "Stage done callback is not present");
bool l_is_last_stage = (a_client_pvt->stage == a_client_pvt->stage_target);
if(l_is_last_stage) { if(l_is_last_stage) {
log_it(L_NOTICE, "Stage %s is achieved", log_it(L_NOTICE, "Stage %s is achieved",
dap_client_stage_str(a_client_pvt->stage)); dap_client_stage_str(a_client_pvt->stage));
...@@ -398,8 +398,9 @@ static void s_stage_status_after(dap_client_pvt_t * a_client_pvt) ...@@ -398,8 +398,9 @@ static void s_stage_status_after(dap_client_pvt_t * a_client_pvt)
// Expecting that its one-shot callback // Expecting that its one-shot callback
a_client_pvt->stage_target_done_callback = NULL; a_client_pvt->stage_target_done_callback = NULL;
} }
} else } else{
log_it(L_ERROR, "!! dap_CLIENT_STAGE_STATUS_DONE but not l_is_last_stage !!"); log_it(L_ERROR, "!! dap_CLIENT_STAGE_STATUS_DONE but not l_is_last_stage (cur stage=%d, target=%d)!!",a_client_pvt->stage, a_client_pvt->stage_target);
}
} }
break; break;
default: default:
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment