* Invoke ep_disconnect to clean up outstanding connections
*/
(void) dapl_ep_disconnect (ep_ptr, DAT_CLOSE_ABRUPT_FLAG);
- dapl_os_assert (ep_ptr->param.ep_state == DAT_EP_STATE_DISCONNECTED ||
- ep_ptr->param.ep_state == DAT_EP_STATE_UNCONNECTED);
/*
* Do verification of parameters and the state change atomically.
*/
dapl_os_lock ( &ep_ptr->header.lock );
+#ifdef DAPL_DBG
+ /* check if event pending and warn, don't assert, state is valid */
+ if (ep_ptr->param.ep_state == DAT_EP_STATE_DISCONNECT_PENDING) {
+ dapl_dbg_log (DAPL_DBG_TYPE_WARN, " dat_ep_free WARNING: "
+ "EVENT PENDING on ep %p, disconnect "
+ "and wait before calling dat_ep_free\n",
+ ep_ptr);
+ }
+#endif
+
if (ep_ptr->cxn_timer != NULL)
{
dapls_timer_cancel ( ep_ptr->cxn_timer );