-
-
Notifications
You must be signed in to change notification settings - Fork 14.4k
Update comments in do_exec and add assertion for fd flag #147656
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
base: main
Are you sure you want to change the base?
Conversation
|
r? @ibraheemdev rustbot has assigned @ibraheemdev. Use |
|
See #147624 (comment) for why I don't think this is necessary. |
| // SAFETY: Dropping `stdio` (ChildPipes) is safe here since ChildPipes | ||
| // does not involve heap memory allocations | ||
| debug_assert!(size_of::<ChildPipes>() <= 24); | ||
| drop(stdio); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agreed with joboet that we shouldn't need this. If anything, you could do a debug_assert with F_GETFL that ensures F_CLOEXEC is set.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah, I changed the PR to update outdated comments and add debug_assertion.
3f065a5 to
30b8146
Compare
Fixes #147624