mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-09-03 08:08:43 +00:00
LibC: Declare sockaddr_storage
This type is guaranteed to fit the largest sockaddr_foo supported by the system. In our case, that's sockaddr_un.
This commit is contained in:
parent
9ba9228a6b
commit
eeb9042b8e
Notes:
sideshowbarker
2024-07-19 03:53:23 +09:00
Author: https://github.com/awesomekling
Commit: eeb9042b8e
1 changed files with 7 additions and 0 deletions
|
@ -86,6 +86,13 @@ struct ucred {
|
|||
#define SO_BINDTODEVICE 7
|
||||
#define SO_KEEPALIVE 9
|
||||
|
||||
struct sockaddr_storage {
|
||||
union {
|
||||
char data[sizeof(sockaddr_un)];
|
||||
void* alignment;
|
||||
};
|
||||
};
|
||||
|
||||
int socket(int domain, int type, int protocol);
|
||||
int bind(int sockfd, const struct sockaddr* addr, socklen_t);
|
||||
int listen(int sockfd, int backlog);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue