mirror of
https://git.h3cjp.net/H3cJP/citra.git
synced 2024-11-24 08:32:57 +00:00
Merge pull request #4669 from wwylele/rpc-server-freeze
rpc: send ending packet in Server instead of UDPServer
This commit is contained in:
commit
5954dc11ba
|
@ -25,6 +25,7 @@ void Server::Start() {
|
|||
|
||||
void Server::Stop() {
|
||||
udp_server.reset();
|
||||
NewRequestCallback(nullptr); // Notify the RPC server to end
|
||||
}
|
||||
|
||||
void Server::NewRequestCallback(std::unique_ptr<RPC::Packet> new_request) {
|
||||
|
|
|
@ -20,10 +20,7 @@ public:
|
|||
new_request_callback(std::move(new_request_callback)) {
|
||||
|
||||
StartReceive();
|
||||
worker_thread = std::thread([this] {
|
||||
io_context.run();
|
||||
this->new_request_callback(nullptr);
|
||||
});
|
||||
worker_thread = std::thread([this] { io_context.run(); });
|
||||
}
|
||||
|
||||
~Impl() {
|
||||
|
|
Loading…
Reference in a new issue