| 119 | } |
| 120 | |
| 121 | static void |
| 122 | read_events(lrmd_event_data_t * event) |
| 123 | { |
| 124 | report_event(event); |
| 125 | if (options.listen) { |
| 126 | if (safe_str_eq(options.listen, event_buf_v0)) { |
| 127 | print_result(printf("LISTEN EVENT SUCCESSFUL\n")); |
| 128 | test_exit(0); |
| 129 | } |
| 130 | } |
| 131 | |
| 132 | if (exec_call_id && (event->call_id == exec_call_id)) { |
| 133 | if (event->op_status == 0 && event->rc == 0) { |
| 134 | print_result(printf("API-CALL SUCCESSFUL for 'exec'\n")); |
| 135 | } else { |
| 136 | print_result(printf("API-CALL FAILURE for 'exec', rc:%d lrmd_op_status:%s\n", |
| 137 | event->rc, services_lrm_status_str(event->op_status))); |
| 138 | test_exit(-1); |
| 139 | } |
| 140 | |
| 141 | if (!options.listen) { |
| 142 | test_exit(0); |
| 143 | } |
| 144 | } |
| 145 | } |
| 146 | |
| 147 | static gboolean |
| 148 | timeout_err(gpointer data) |
nothing calls this directly
no test coverage detected