Improve thread aborting mechanism (#10490)

Call pseudo-virtual operator=(thread_state) of thread context.
This commit is contained in:
Eladash 2021-06-27 11:43:48 +03:00 committed by GitHub
parent 58847fa2ca
commit 0aed00a758
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 31 additions and 44 deletions

View file

@ -296,7 +296,7 @@ static void network_clear_queue(ppu_thread& ppu)
}
// Object in charge of retransmiting packets for STREAM_P2P sockets
class tcp_timeout_monitor : public need_wakeup
class tcp_timeout_monitor
{
public:
void add_message(s32 sock_id, const sockaddr_in *dst, std::vector<u8> data, u64 seq)
@ -423,9 +423,10 @@ public:
}
}
void wake_up()
tcp_timeout_monitor& operator=(thread_state)
{
wakey.notify_one();
return *this;
}
public: