| 1226 | } |
| 1227 | |
| 1228 | static bool runtime_worker_handle_unsubscribe(cbm_daemon_runtime_worker_t *worker, |
| 1229 | const uint8_t *payload, uint32_t length) { |
| 1230 | if (!runtime_worker_service_running(worker) || !payload || length != UNSUBSCRIBE_REQUEST_SIZE) { |
| 1231 | return false; |
| 1232 | } |
| 1233 | cbm_daemon_subscription_id_t subscription_id = runtime_get_u64(payload); |
| 1234 | bool removed = cbm_daemon_job_unsubscribe(worker->service->coordinator, worker->client_id, |
| 1235 | subscription_id); |
| 1236 | return runtime_worker_send_status(worker, CBM_DAEMON_RUNTIME_OP_JOB_UNSUBSCRIBE, removed); |
| 1237 | } |
| 1238 | |
| 1239 | static void *runtime_application_worker(void *opaque) { |
| 1240 | cbm_daemon_runtime_worker_t *worker = opaque; |
no test coverage detected