| 510 | } |
| 511 | |
| 512 | gboolean |
| 513 | stonith_constraints(node_t * node, action_t * stonith_op, pe_working_set_t * data_set) |
| 514 | { |
| 515 | CRM_CHECK(stonith_op != NULL, return FALSE); |
| 516 | |
| 517 | /* |
| 518 | * Make sure the stonith OP occurs before we start any shared resources |
| 519 | */ |
| 520 | if (stonith_op != NULL) { |
| 521 | GListPtr lpc = NULL; |
| 522 | |
| 523 | for (lpc = data_set->resources; lpc != NULL; lpc = lpc->next) { |
| 524 | resource_t *rsc = (resource_t *) lpc->data; |
| 525 | |
| 526 | rsc_stonith_ordering(rsc, stonith_op, data_set); |
| 527 | } |
| 528 | } |
| 529 | |
| 530 | /* add the stonith OP as a stop pre-req and the mark the stop |
| 531 | * as a pseudo op - since its now redundant |
| 532 | */ |
| 533 | |
| 534 | return TRUE; |
| 535 | } |
| 536 | |
| 537 | xmlNode * |
| 538 | action2xml(action_t * action, gboolean as_input) |
no test coverage detected