mirror of
https://github.com/LadybirdBrowser/ladybird
synced 2026-04-26 01:35:08 +02:00
LibCore: Move Stream-based sockets into the Core namespace
This commit is contained in:
committed by
Linus Groh
parent
d43a7eae54
commit
a96339b72b
Notes:
sideshowbarker
2024-07-17 07:25:39 +09:00
Author: https://github.com/timschumi Commit: https://github.com/SerenityOS/serenity/commit/a96339b72b Pull-request: https://github.com/SerenityOS/serenity/pull/17406 Reviewed-by: https://github.com/linusg
@@ -338,7 +338,7 @@ public:)~~~");
|
||||
static i32 static_message_id() { return (int)MessageID::@message.pascal_name@; }
|
||||
virtual const char* message_name() const override { return "@endpoint.name@::@message.pascal_name@"; }
|
||||
|
||||
static ErrorOr<NonnullOwnPtr<@message.pascal_name@>> decode(AK::Stream& stream, Core::Stream::LocalSocket& socket)
|
||||
static ErrorOr<NonnullOwnPtr<@message.pascal_name@>> decode(AK::Stream& stream, Core::LocalSocket& socket)
|
||||
{
|
||||
IPC::Decoder decoder { stream, socket };)~~~");
|
||||
|
||||
@@ -584,7 +584,7 @@ public:
|
||||
|
||||
static u32 static_magic() { return @endpoint.magic@; }
|
||||
|
||||
static ErrorOr<NonnullOwnPtr<IPC::Message>> decode_message(ReadonlyBytes buffer, [[maybe_unused]] Core::Stream::LocalSocket& socket)
|
||||
static ErrorOr<NonnullOwnPtr<IPC::Message>> decode_message(ReadonlyBytes buffer, [[maybe_unused]] Core::LocalSocket& socket)
|
||||
{
|
||||
FixedMemoryStream stream { buffer };
|
||||
auto message_endpoint_magic = TRY(stream.read_value<u32>());)~~~");
|
||||
|
||||
Reference in New Issue
Block a user