Skip to content

wasip3: implement fcntl#745

Closed
rvolosatovs wants to merge 1 commit intoWebAssembly:mainfrom
rvolosatovs:p3-fcntl
Closed

wasip3: implement fcntl#745
rvolosatovs wants to merge 1 commit intoWebAssembly:mainfrom
rvolosatovs:p3-fcntl

Conversation

@rvolosatovs
Copy link
Contributor

@rvolosatovs rvolosatovs commented Feb 20, 2026

Implement fcntl

Eventually, we should unify the UDP implementations (#728 (review)). If most other socket-related PRs are merged, I might tackle this next week Monday, otherwise it seems that doing so now would introduce quite a bit of churn.

This is blocked on #725

Unfortunately, due to the way sockets-nonblocking-udp is set up we cannot implement support for UDP just in socket and nowhere else, so bring along some fairly trivial UDP logic from wasip2 and introduce an abort() in poll for now.

TEST(bind(server_socket_fd, (struct sockaddr *)&server_address,
sizeof(server_address)) != -1);

@alexcrichton
Copy link
Collaborator

Upon reflection about #725, I actually think it'd be best to go in a different direction. WDYT about merging wasip{2,3}_tcp.c and tcp_sockopt.c all in one file? Similar for wasip{2,3}_udp.c and having that all in one file.

I'd like to by-default share things and we can split helpers out if necessary, but I think there's going to be a lot more shared code than not in the structure of these files.

Signed-off-by: Roman Volosatovs <rvolosatovs@riseup.net>
alexcrichton pushed a commit that referenced this pull request Feb 24, 2026
Merge TCP implementations in `tcp.c` as suggested in
#745 (comment)

---------

Signed-off-by: Roman Volosatovs <rvolosatovs@riseup.net>
@alexcrichton
Copy link
Collaborator

As a heads up if you're out of time on this @rvolosatovs I've done some work in #750 to resolve merge conflicts and address some thoughts of mine

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants