MCPcopy Create free account
hub / github.com/corosync/corosync / using_votequorum

Function using_votequorum

tools/corosync-quorumtool.c:214–232  ·  view source on GitHub ↗

* Returns 1 if 'votequorum' is active. The called then knows that * votequorum calls should work and can provide extra information */

Source from the content-addressed store, hash-verified

212 * votequorum calls should work and can provide extra information
213 */
214static int using_votequorum(void)
215{
216 char quorumtype[256];
217 int using_voteq;
218
219 memset(quorumtype, 0, sizeof(quorumtype));
220
221 if (get_quorum_type(quorumtype, sizeof(quorumtype))) {
222 return -1;
223 }
224
225 if (strcmp(quorumtype, "corosync_votequorum") == 0) {
226 using_voteq = 1;
227 } else {
228 using_voteq = 0;
229 }
230
231 return using_voteq;
232}
233
234static int set_votes(uint32_t nodeid, int votes)
235{

Callers 4

show_statusFunction · 0.85
monitor_statusFunction · 0.85
init_allFunction · 0.85
mainFunction · 0.85

Calls 1

get_quorum_typeFunction · 0.85

Tested by

no test coverage detected