| 497 | } |
| 498 | |
| 499 | static void |
| 500 | action_complete(svc_action_t * action) |
| 501 | { |
| 502 | lrmd_rsc_t *rsc; |
| 503 | lrmd_cmd_t *cmd = action->cb_data; |
| 504 | |
| 505 | if (!cmd) { |
| 506 | crm_err("LRMD action (%s) completed does not match any known operations.", action->id); |
| 507 | return; |
| 508 | } |
| 509 | #ifdef HAVE_SYS_TIMEB_H |
| 510 | if (cmd->exec_rc != action->rc) { |
| 511 | ftime(&cmd->t_rcchange); |
| 512 | } |
| 513 | #endif |
| 514 | |
| 515 | cmd->exec_rc = get_uniform_rc(action->standard, cmd->action, action->rc); |
| 516 | cmd->lrmd_op_status = action->status; |
| 517 | rsc = cmd->rsc_id ? g_hash_table_lookup(rsc_list, cmd->rsc_id) : NULL; |
| 518 | |
| 519 | if (action->stdout_data) { |
| 520 | cmd->output = strdup(action->stdout_data); |
| 521 | } |
| 522 | |
| 523 | cmd_finalize(cmd, rsc); |
| 524 | } |
| 525 | |
| 526 | |
| 527 | static void |
nothing calls this directly
no test coverage detected