Delete AsyncSocket class, merge into Socket class

Bug: webrtc:13065
Change-Id: I13afee2386ea9c4de0e4fa95133f0c4d3ec826e8
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/227031
Reviewed-by: Harald Alvestrand <hta@webrtc.org>
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Niels Moller <nisse@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#34787}
This commit is contained in:
Niels Möller
2021-08-12 10:32:30 +02:00
committed by WebRTC LUCI CQ
parent 45b3e530cb
commit d0b8879770
73 changed files with 570 additions and 685 deletions

View File

@ -69,10 +69,9 @@ class RTC_EXPORT PhysicalSocketServer : public SocketServer {
// SocketFactory:
Socket* CreateSocket(int family, int type) override;
AsyncSocket* CreateAsyncSocket(int family, int type) override;
// Internal Factory for Accept (virtual so it can be overwritten in tests).
virtual AsyncSocket* WrapSocket(SOCKET s);
virtual Socket* WrapSocket(SOCKET s);
// SocketServer:
bool Wait(int cms, bool process_io) override;
@ -130,7 +129,7 @@ class RTC_EXPORT PhysicalSocketServer : public SocketServer {
bool waiting_ = false;
};
class PhysicalSocket : public AsyncSocket, public sigslot::has_slots<> {
class PhysicalSocket : public Socket, public sigslot::has_slots<> {
public:
PhysicalSocket(PhysicalSocketServer* ss, SOCKET s = INVALID_SOCKET);
~PhysicalSocket() override;
@ -164,7 +163,7 @@ class PhysicalSocket : public AsyncSocket, public sigslot::has_slots<> {
int64_t* timestamp) override;
int Listen(int backlog) override;
AsyncSocket* Accept(SocketAddress* out_addr) override;
Socket* Accept(SocketAddress* out_addr) override;
int Close() override;