mirror of
https://gitlab.com/niansa/cosched.git
synced 2025-03-06 20:53:26 +01:00
Renamed ScheduledThread::enqueue to create_task
This commit is contained in:
parent
19b29577a1
commit
6a225e88df
1 changed files with 2 additions and 2 deletions
|
@ -38,7 +38,7 @@ public:
|
|||
}
|
||||
|
||||
// DO NOT call from within a task
|
||||
void enqueue(const std::string& task_name, const std::function<async::result<void> ()>& task_fcn) {
|
||||
void create_task(const std::string& task_name, const std::function<async::result<void> ()>& task_fcn) {
|
||||
// Enqueue function
|
||||
{
|
||||
std::scoped_lock L(queue_mutex);
|
||||
|
@ -57,7 +57,7 @@ public:
|
|||
|
||||
// MUST already be running
|
||||
void shutdown() {
|
||||
enqueue("Shutdown Initiator", [this] () -> async::result<void> {
|
||||
create_task("Shutdown Initiator", [this] () -> async::result<void> {
|
||||
shutdown_requested = true;
|
||||
co_return;
|
||||
});
|
||||
|
|
Loading…
Add table
Reference in a new issue