Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement blocking unnamed_socket #4072

Merged
merged 1 commit into from
Dec 18, 2024
Merged

Implement blocking unnamed_socket #4072

merged 1 commit into from
Dec 18, 2024

Conversation

tiif
Copy link
Contributor

@tiif tiif commented Dec 4, 2024

Support blocking for socketpair and pipe.

closes #3665

@rustbot rustbot added the S-waiting-on-author Status: Waiting for the PR author to address review comments label Dec 4, 2024
@tiif
Copy link
Contributor Author

tiif commented Dec 4, 2024

Planning to open a minor clean-up PR to remove some unused variable here before getting back to this.

@rustbot label S-blocked

@rustbot rustbot added the S-blocked Status: blocked on something happening somewhere else label Dec 4, 2024
@bors
Copy link
Contributor

bors commented Dec 5, 2024

☔ The latest upstream changes (presumably #4074) made this pull request unmergeable. Please resolve the merge conflicts.

@tiif tiif changed the title [WIP] blocking unnamed_socket Implement blocking unnamed_socket Dec 16, 2024
Comment on lines +172 to +173
let Some(self_ref) = weak_self_ref.upgrade() else {
// FIXME: We should raise a deadlock error if the self_ref upgrade failed.
throw_unsup_format!("This will be a deadlock error in future")
};
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this PR is big enough, so I decided to temporarily make this throws unsupported format.

I wanted to write a test for this, and potentially tweak the diagnostic a bit if it is too confusing (because of the reason stated here).

But I certainly won't mind putting it in this PR if anyone prefers.

@tiif
Copy link
Contributor Author

tiif commented Dec 16, 2024

@rustbot ready

@rustbot rustbot added S-waiting-on-review Status: Waiting for a review to complete and removed S-waiting-on-author Status: Waiting for the PR author to address review comments S-blocked Status: blocked on something happening somewhere else labels Dec 16, 2024
@tiif tiif marked this pull request as ready for review December 16, 2024 14:22
Copy link
Contributor

@oli-obk oli-obk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just some nits, then this is ready, please apply and squash

src/shims/unix/unnamed_socket.rs Outdated Show resolved Hide resolved
src/shims/unix/unnamed_socket.rs Outdated Show resolved Hide resolved
src/shims/unix/unnamed_socket.rs Outdated Show resolved Hide resolved
src/shims/unix/unnamed_socket.rs Outdated Show resolved Hide resolved
src/shims/unix/unnamed_socket.rs Outdated Show resolved Hide resolved
src/shims/unix/unnamed_socket.rs Outdated Show resolved Hide resolved
@oli-obk oli-obk added this pull request to the merge queue Dec 18, 2024
Merged via the queue into rust-lang:master with commit c9c28f4 Dec 18, 2024
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-review Status: Waiting for a review to complete
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Implement blocking support for eventfd and socketpair
4 participants