mirror of
https://github.com/espressif/esp-idf.git
synced 2026-10-02 11:10:54 +03:00
refactor: avoid function calls inside MIN/MAX macros
This commit is contained in:
@@ -192,7 +192,8 @@ esp_err_t ESP_SYSTEM_IRAM_ATTR esp_backtrace_print_all_tasks(int depth)
|
||||
&ctrl.cur_tasks[core_id].next_pc);
|
||||
|
||||
// Get snapshot of all tasks in the system
|
||||
const UBaseType_t num_snapshots = MIN(num_tasks, uxTaskGetSnapshotAll(task_snapshots, num_tasks, NULL));
|
||||
UBaseType_t snapshot_count = uxTaskGetSnapshotAll(task_snapshots, num_tasks, NULL);
|
||||
const UBaseType_t num_snapshots = MIN(num_tasks, snapshot_count);
|
||||
// Print the backtrace of every task in the system
|
||||
for (UBaseType_t task_idx = 0; task_idx < num_snapshots; task_idx++) {
|
||||
bool cur_running = false;
|
||||
|
||||
Reference in New Issue
Block a user