* Returns 1 if 'votequorum' is active. The called then knows that * votequorum calls should work and can provide extra information */
| 212 | * votequorum calls should work and can provide extra information |
| 213 | */ |
| 214 | static 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 | |
| 234 | static int set_votes(uint32_t nodeid, int votes) |
| 235 | { |
no test coverage detected