handler_instance->handler = handler;
handler_instance->arg = handler_arg;
- if(SLIST_EMPTY(handlers)) {
+ if (SLIST_EMPTY(handlers)) {
SLIST_INSERT_HEAD(handlers, handler_instance, next);
}
else {
return ESP_OK;
on_err:
- if(loop->queue != NULL) {
+ if (loop->queue != NULL) {
vQueueDelete(loop->queue);
}
- if(loop->mutex != NULL) {
+ if (loop->mutex != NULL) {
vSemaphoreDelete(loop->mutex);
}
#ifdef CONFIG_ESP_EVENT_LOOP_PROFILING
- if(loop->profiling_mutex != NULL) {
+ if (loop->profiling_mutex != NULL) {
vSemaphoreDelete(loop->profiling_mutex);
}
#endif
TickType_t marker = xTaskGetTickCount();
TickType_t end = 0;
-#if( configUSE_16_BIT_TICKS == 1 )
+#if (configUSE_16_BIT_TICKS == 1)
int32_t remaining_ticks = ticks_to_run;
#else
int64_t remaining_ticks = ticks_to_run;
}
SLIST_FOREACH(id_node, &(base_node->id_nodes), next) {
- if(id_node->id == post.id) {
+ if (id_node->id == post.id) {
// Execute id level handlers
SLIST_FOREACH(handler, &(id_node->handlers), next) {
handler_execute(loop, handler, post);