This commit is contained in:
jeka committed 2026-03-05 15:05:20 +03:00
1 parent 357169a38a
commit 69d33636bf
2 files changed
+11 -2

No files matched your search

+9 -2
View File
@@ -262,7 +262,9 @@ int queue_data_put(struct ll_queue* q, struct ll_entry* entry, uint32_t id) {
// Проверить ожидающие коллбэки
check_waiters(q);
#ifdef QUEUE_DEBUG
queue_check_consistency(q);// !!!! for debug
#endif
return 0;
}
@@ -303,7 +305,9 @@ int queue_data_put_first(struct ll_queue* q, struct ll_entry* entry, uint32_t id
// Проверить ожидающие коллбэки
check_waiters(q);
#ifdef QUEUE_DEBUG
queue_check_consistency(q);// !!!! for debug
#endif
return 0;
}
@@ -332,7 +336,9 @@ struct ll_entry* queue_data_get(struct ll_queue* q) {
// Проверить ожидающие коллбэки
check_waiters(q);
#ifdef QUEUE_DEBUG
queue_check_consistency(q);// !!!! for debug
#endif
return entry;
}
@@ -450,7 +456,8 @@ int queue_remove_data(struct ll_queue* q, struct ll_entry* entry) {
remove_from_hash(q, entry);
// DEBUG_DEBUG(DEBUG_CATEGORY_LL_QUEUE, "queue_remove_data: removed entry %p (id=%u), count=%d", entry, entry->id, q->count);
#ifdef QUEUE_DEBUG
queue_check_consistency(q);// !!!! for debug
#endif
return 0;
}
}
+2
View File
@@ -5,6 +5,8 @@
#include <stdint.h> // для uint64_t
#include "memory_pool.h" // для struct memory_pool
#define QUEUE_DEBUG 1
/**
* @file ll_queue.h
* @brief Упрощённая двусвязная очередь с поддержкой автозабора элементов через callback,