- **summary**: log: Correct assigning the signal wait for server --> log: Check
the value of waiting variable before assigning
---
** [tickets:#3301] log: Check the value of waiting variable before assigning**
**Status:** accepted
**Milestone:** 5.21.12
**Created:** Thu Dec 09, 2021 08:50 AM UTC by Hieu Hong Hoang
**Last Updated:** Fri Dec 10, 2021 12:38 AM UTC
**Owner:** Hieu Hong Hoang
In [ticket 3291](https://sourceforge.net/p/opensaf/tickets/3291/), the
following code was added:
~~~
done:
if (CountClient() == 0) {
// Stop recovery thread if it's running
stop_recovery2_thread();
// Shutdown the agent
rc = lga_shutdown();
if (rc != NCSCC_RC_SUCCESS) {
TRACE("lga_shutdown FAILED");
ais_rc = SA_AIS_ERR_LIBRARY;
}
m_NCS_SEL_OBJ_RMV_IND(&init_clm_status_sel_, true, false);
m_NCS_SEL_OBJ_RMV_IND(&log_server_up_sel_, true, false);
atomic_data_.waiting_log_server_up = true;
}
~~~
The signal wait for server was assigned without checking its value. We should
only assign if it wasn't.
---
Sent from sourceforge.net because opensaf-tickets@lists.sourceforge.net is
subscribed to https://sourceforge.net/p/opensaf/tickets/
To unsubscribe from further messages, a project admin can change settings at
https://sourceforge.net/p/opensaf/admin/tickets/options. Or, if this is a
mailing list, you can unsubscribe from the mailing list.
_______________________________________________
Opensaf-tickets mailing list
Opensaf-tickets@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/opensaf-tickets