mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 17:47:44 +00:00
Kernel+LibC: Use uintptr_t as the main type in the syscall interface
This commit is contained in:
parent
583bfa04e2
commit
65cdac1a5b
5 changed files with 25 additions and 19 deletions
|
@ -103,7 +103,7 @@ ssize_t recvfrom(int sockfd, void* buffer, size_t buffer_length, int flags, stru
|
|||
|
||||
sockaddr_storage internal_addr;
|
||||
iovec iov = { buffer, buffer_length };
|
||||
msghdr msg = { addr ? &internal_addr : nullptr, addr ? sizeof(internal_addr) : 0, &iov, 1, nullptr, 0, 0 };
|
||||
msghdr msg = { addr ? &internal_addr : nullptr, addr ? (socklen_t)sizeof(internal_addr) : 0, &iov, 1, nullptr, 0, 0 };
|
||||
ssize_t rc = recvmsg(sockfd, &msg, flags);
|
||||
if (rc >= 0 && addr) {
|
||||
memcpy(addr, &internal_addr, min(*addr_length, msg.msg_namelen));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue