Skip to content

Commit

Permalink
kargs: Handle when kargs.d doesn't exist
Browse files Browse the repository at this point in the history
I'm experimenting with custom base images and hit on this
not existing.

Signed-off-by: Colin Walters <[email protected]>
  • Loading branch information
cgwalters committed Nov 8, 2024
1 parent 1507a58 commit 64a86eb
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions lib/src/kargs.rs
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,9 @@ pub(crate) fn get_kargs_from_ostree_root(
) -> Result<Vec<String>> {
let kargsd = root.resolve_relative_path(KARGS_PATH);
let kargsd = kargsd.downcast_ref::<ostree::RepoFile>().expect("downcast");
if !kargsd.query_exists(gio::Cancellable::NONE) {
return Ok(Default::default());
}
get_kargs_from_ostree(repo, kargsd, sys_arch)
}

Expand Down

0 comments on commit 64a86eb

Please sign in to comment.