mirror of
https://github.com/fergalmoran/ladybird.git
synced 2026-02-24 00:24:38 +00:00
LibCore: Move Stream-based sockets into the Core namespace
This commit is contained in:
committed by
Linus Groh
parent
d43a7eae54
commit
a96339b72b
@@ -23,6 +23,7 @@
|
||||
#include <LibCore/Notifier.h>
|
||||
#include <LibCore/Object.h>
|
||||
#include <LibCore/SessionManagement.h>
|
||||
#include <LibCore/Socket.h>
|
||||
#include <LibThreading/Mutex.h>
|
||||
#include <LibThreading/MutexProtected.h>
|
||||
#include <errno.h>
|
||||
@@ -156,7 +157,7 @@ pid_t EventLoop::s_pid;
|
||||
class InspectorServerConnection : public Object {
|
||||
C_OBJECT(InspectorServerConnection)
|
||||
private:
|
||||
explicit InspectorServerConnection(NonnullOwnPtr<Stream::LocalSocket> socket)
|
||||
explicit InspectorServerConnection(NonnullOwnPtr<LocalSocket> socket)
|
||||
: m_socket(move(socket))
|
||||
, m_client_id(s_id_allocator.with_locked([](auto& allocator) {
|
||||
return allocator->allocate();
|
||||
@@ -305,7 +306,7 @@ public:
|
||||
}
|
||||
|
||||
private:
|
||||
NonnullOwnPtr<Stream::LocalSocket> m_socket;
|
||||
NonnullOwnPtr<LocalSocket> m_socket;
|
||||
WeakPtr<Object> m_inspected_object;
|
||||
int m_client_id { -1 };
|
||||
};
|
||||
@@ -370,7 +371,7 @@ bool connect_to_inspector_server()
|
||||
return false;
|
||||
}
|
||||
auto inspector_server_path = maybe_path.value();
|
||||
auto maybe_socket = Stream::LocalSocket::connect(inspector_server_path, Stream::PreventSIGPIPE::Yes);
|
||||
auto maybe_socket = LocalSocket::connect(inspector_server_path, Socket::PreventSIGPIPE::Yes);
|
||||
if (maybe_socket.is_error()) {
|
||||
dbgln("connect_to_inspector_server: Failed to connect: {}", maybe_socket.error());
|
||||
return false;
|
||||
|
||||
Reference in New Issue
Block a user