Commit graph

6 commits

Author SHA1 Message Date
Timothy Flynn
005e965380 LibCore+RequestServer: Return size_t from system read/write functions
The system uses ssize_t so it can return -1 in case of an error. But in
our case, we will transform that to an AK::Error, thus we never return
-1. Let's return size_t instead.
2025-12-01 16:29:48 +01:00
Timothy Flynn
85fd4d5ea1 LibCore: Accept ReadonlyBytes/Bytes in System::send/recv
Instead of passing in a pointer+size, let's use safer AK types.
2025-12-01 08:55:33 -05:00
Timothy Flynn
90525f7e97 LibCore: Define SocketAddress out-of-line to remove SocketAddressWindows
SocketAddressWindows.h contains a bunch of copy-pasted Windows
definitions. This started causing ad-nauseam redefinition errors when
implementing the HTTP disk cache for Windows.

Instead, let's forward-declare the types we can in SocketAddress.h and
only define the couple of constants that we need. We can then assert at
compile-time that we defined them correctly.
2025-12-01 06:34:32 -05:00
Andreas Kling
fa8592b4a9 LibCore: Remove unused UDPServer constructor parameter 2025-08-11 16:55:25 +02:00
Andreas Kling
ecf0395c27 LibCore: Stop parenting notifiers
There's no need to participate in the ancient EventReceiver parent/child
ownership scheme here. Notifiers are already owned by RefPtrs anyway.
2025-08-11 16:55:25 +02:00
ayeteadoe
904f736b95 LibCore: Implement UDPServer on Windows 2025-08-06 20:24:38 -06:00