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

Use an RAII wrapper for stdio redirection #260

Merged
merged 2 commits into from
Aug 23, 2023
Merged

Conversation

jprendes
Copy link
Collaborator

This PR introduces an RAII wrapper to hande stdio redirection.
The wrapper handles the lifetime of the file descriptors involved.
It also introduces Windows support for stdio redirection.

@jprendes jprendes marked this pull request as ready for review August 21, 2023 22:01
@jprendes jprendes force-pushed the stdio branch 2 times, most recently from 394b86c to 439c34f Compare August 21, 2023 22:50
Mossaka
Mossaka previously approved these changes Aug 21, 2023
Copy link
Member

@Mossaka Mossaka left a comment

Choose a reason for hiding this comment

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

LGTM! Asked a few questions

Copy link
Contributor

Choose a reason for hiding this comment

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

I put the sys folder up at the /src/ folder level in #238. thoughts on which level it should be on?

Mossaka
Mossaka previously approved these changes Aug 22, 2023
@Mossaka
Copy link
Member

Mossaka commented Aug 22, 2023

Need a rebase

Mossaka
Mossaka previously approved these changes Aug 22, 2023
Copy link
Member

@Mossaka Mossaka left a comment

Choose a reason for hiding this comment

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

LGTM! Thanks

@jsturtevant
Copy link
Contributor

is #260 (comment) the location we want? otherwise lgtm

@jprendes
Copy link
Collaborator Author

is #260 (comment) the location we want? otherwise lgtm

I'll fix that tomorrow. I'm AFK.

Signed-off-by: Jorge Prendes <[email protected]>
@jprendes
Copy link
Collaborator Author

jprendes commented Aug 23, 2023

I moved the stio within the sys module from #238 . I also took the opportunity to split up the sys modules into smaller submodules and make it only pub(crate).

@jprendes jprendes force-pushed the stdio branch 2 times, most recently from 436c505 to 569f8e3 Compare August 23, 2023 15:03
@Mossaka Mossaka merged commit 153fbc3 into containerd:main Aug 23, 2023
9 checks passed
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.

3 participants