Skip to content

Commit

Permalink
.
Browse files Browse the repository at this point in the history
  • Loading branch information
TrentHouliston committed Aug 14, 2024
1 parent f295e46 commit c028329
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/threading/TaskScheduler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -92,8 +92,8 @@ namespace threading {

TaskScheduler::TaskScheduler(const size_t& thread_count) {
// Make the queue for the main thread
pool_queues[util::ThreadPoolDescriptor::MAIN_THREAD_POOL_ID] = std::make_shared<PoolQueue>(
util::ThreadPoolDescriptor{"Main Thread", util::ThreadPoolDescriptor::MAIN_THREAD_POOL_ID, 1, true});
auto main_descriptor = dsl::word::MainThread::descriptor();
pool_queues[main_descriptor.pool_id] = std::make_shared<PoolQueue>(main_descriptor);

// Make the default pool with the correct number of threads
auto default_descriptor = util::ThreadPoolDescriptor{};
Expand Down Expand Up @@ -139,7 +139,7 @@ namespace threading {
}

// Run main thread tasks
pool_func(pool_queues.at(util::ThreadPoolDescriptor::MAIN_THREAD_POOL_ID));
pool_func(pool_queues.at(NUClear::id_t(util::ThreadPoolDescriptor::MAIN_THREAD_POOL_ID)));

/**
* Once the main thread reaches this point it is because the powerplant, and by extension the scheduler, have
Expand Down

0 comments on commit c028329

Please sign in to comment.