| 100 | } |
| 101 | |
| 102 | void pn_handler_dispatch(pn_handler_t *handler, pn_event_t *event, pn_event_type_t type) { |
| 103 | assert(handler); |
| 104 | if (handler->dispatch) { |
| 105 | handler->dispatch(handler, event, type); |
| 106 | } |
| 107 | if (handler->children) { |
| 108 | size_t n = pn_list_size(handler->children); |
| 109 | for (size_t i = 0; i < n; i++) { |
| 110 | pn_handler_t *child = (pn_handler_t *) pn_list_get(handler->children, i); |
| 111 | pn_handler_dispatch(child, event, type); |
| 112 | } |
| 113 | } |
| 114 | } |
no test coverage detected