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

exec/util: fix infinite loop in Depth() if -root is relative #1359

Merged
merged 1 commit into from May 10, 2022
Merged

exec/util: fix infinite loop in Depth() if -root is relative #1359

merged 1 commit into from May 10, 2022

Conversation

bgilbert
Copy link
Contributor

@bgilbert bgilbert commented May 6, 2022

If the -root command-line argument isn't an absolute path, and the files stage tries to write a file, we get stuck in an infinite loop in Depth(). Ignition shouldn't normally be invoked this way, but it might occur during manual debugging. Avoid the infinite loop.

If the -root command-line argument isn't an absolute path, and the files
stage tries to write a file, we get stuck in an infinite loop in Depth().
Ignition shouldn't normally be invoked this way, but it might occur
during manual debugging.  Avoid the infinite loop.
Copy link
Collaborator

@prestist prestist left a comment

Choose a reason for hiding this comment

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

Nice catch. LGTM

Copy link
Member

@dustymabe dustymabe left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Member

@jlebon jlebon left a comment

Choose a reason for hiding this comment

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

Ignition shouldn't normally be invoked this way, but it might occur during manual debugging.

It might also be more likely in the ignition-apply path.

@bgilbert bgilbert merged commit b0def86 into coreos:main May 10, 2022
@bgilbert bgilbert deleted the path branch May 10, 2022 20:32
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.

None yet

4 participants