Drop SemaphoreActor context.
This commit is contained in:
parent
782aa6a2ec
commit
dcb77ce187
@ -42,6 +42,7 @@
|
||||
#include "td/utils/utf8.h"
|
||||
#include "td/utils/VectorQueue.h"
|
||||
|
||||
#include <memory>
|
||||
#include <tuple>
|
||||
#include <utility>
|
||||
|
||||
@ -66,6 +67,11 @@ class SemaphoreActor final : public Actor {
|
||||
size_t capacity_;
|
||||
VectorQueue<Promise<Promise<Unit>>> pending_;
|
||||
|
||||
void start_up() final {
|
||||
set_context(std::make_shared<ActorContext>());
|
||||
set_tag(string());
|
||||
}
|
||||
|
||||
void finish(Result<Unit>) {
|
||||
capacity_++;
|
||||
if (!pending_.empty()) {
|
||||
|
Loading…
Reference in New Issue
Block a user