- **status**: accepted --> review


---

** [tickets:#3023] osaf: incorrect result from CreateTakeoverRequest**

**Status:** review
**Milestone:** 5.19.06
**Created:** Mon Mar 25, 2019 06:36 AM UTC by Gary Lee
**Last Updated:** Tue Mar 26, 2019 01:56 AM UTC
**Owner:** Gary Lee


Noticed a potential issue while browsing the code. If a takeover request is 
written, but cannot be read again, CreateTakeoverRequest would still return OK

~~~
diff --git a/src/osaf/consensus/consensus.cc b/src/osaf/consensus/consensus.cc
index cf307b317..480f7d2a0 100644
--- a/src/osaf/consensus/consensus.cc
+++ b/src/osaf/consensus/consensus.cc
@@ -433,6 +433,8 @@ SaAisErrorT Consensus::CreateTakeoverRequest(const 
std::string& current_owner,
      return rc;
   }

+  // in case takeover request cannot be read
+  rc = SA_AIS_ERR_FAILED_OPERATION;
   // wait up to max_takeover_retry seconds for request to be answered
   retries = 0;
   while (retries < max_takeover_retry_) {
~~~



---

Sent from sourceforge.net because [email protected] 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
[email protected]
https://lists.sourceforge.net/lists/listinfo/opensaf-tickets

Reply via email to