Skip to content

Conversation

@jplatte
Copy link
Member

@jplatte jplatte commented Jan 5, 2025

Haven't tested it 😅
But it compiles now and I got no more energy for this stuff for today.

add_mount(None, "/", None, MsFlags::MS_REC | MsFlags::MS_PRIVATE)?;
add_mount(Some(root), root, None, MsFlags::MS_BIND)?;
mount_change("/", MountPropagationFlags::REC | MountPropagationFlags::PRIVATE)
.map_err(|source| ContainerError::MountSetPrivate { source })?;
Copy link
Contributor

Choose a reason for hiding this comment

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

Nit: if you use newtype enum pattern MountSetPrivate(InnerError) you can do

.map_err(ContainerError::MountSetPrivate)

Copy link
Member Author

Choose a reason for hiding this comment

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

I know. I was following the snafu pattern already basically. Do you think I should change it for more consistency with what we already have, for now?

@jplatte jplatte marked this pull request as draft January 9, 2025 22:44
@CLAassistant
Copy link

CLAassistant commented Jan 17, 2025

CLA assistant check
All committers have signed the CLA.

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