| 197 | } |
| 198 | |
| 199 | static bool main_local_command_cancel(void *opaque) { |
| 200 | main_local_maintenance_context_t *context = opaque; |
| 201 | if (!context) { |
| 202 | return false; |
| 203 | } |
| 204 | cbm_mutex_lock(&context->mutex); |
| 205 | bool cancelled = context->server && cbm_mcp_server_cancel_active(context->server); |
| 206 | context->maintenance_cancelled = context->maintenance_cancelled || cancelled; |
| 207 | cbm_mutex_unlock(&context->mutex); |
| 208 | return cancelled; |
| 209 | } |
| 210 | |
| 211 | static bool main_local_maintenance_was_cancelled(main_local_maintenance_context_t *context) { |
| 212 | if (!context) { |
nothing calls this directly
no test coverage detected