Hi Ravi,

Ack from me (legacy test run) with one comment.

Since we move m_NCS_UNLOCK before releasing the mon thread, so it is ok to me if inside avnd_mon_pids(), after taking the LOCK(), we don't hit any cancellation point before UNLOCK(). Otherwise, the thread is canceled while the LOCK is being till taken.

Thanks,

Minh


On 29/03/18 16:59, ravi-sekhar wrote:
---
  src/amf/amfnd/mon.cc | 4 ++--
  1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/amf/amfnd/mon.cc b/src/amf/amfnd/mon.cc
index 9cdfc37..4932d50 100644
--- a/src/amf/amfnd/mon.cc
+++ b/src/amf/amfnd/mon.cc
@@ -161,6 +161,8 @@ uint32_t avnd_mon_req_del(AVND_CB *cb, SaUint64T pid) {
mon_rec = (AVND_MON_REQ *)m_NCS_DBLIST_FIND_FIRST(pid_mon_list); + m_NCS_UNLOCK(&cb->mon_lock, NCS_LOCK_WRITE);
+
    /* No more PIDs exists in the pid_mon_list for monitoring */
    if (!mon_rec) {
      /* destroy the task */
@@ -173,8 +175,6 @@ uint32_t avnd_mon_req_del(AVND_CB *cb, SaUint64T pid) {
      }
    }
- m_NCS_UNLOCK(&cb->mon_lock, NCS_LOCK_WRITE);
-
    return rc;
  }


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Opensaf-devel mailing list
Opensaf-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/opensaf-devel

Reply via email to