# bootc-202512190045.g72f1f2720d-1 - findings not occurring in bootc-202512190045.g72f1f2720d-1

## List of Findings

    Error: COMPILER_WARNING (CWE-704): [#def1]
    bootc-202512190045.g72f1f2720d-build/bootc-202512190045.g72f1f2720d/vendor/libz-sys/src/smoke.c: scope_hint: In function 'main'
    bootc-202512190045.g72f1f2720d-build/bootc-202512190045.g72f1f2720d/vendor/libz-sys/src/smoke.c:4:10: warning[-Wpointer-to-int-cast]: cast from pointer to integer of different size
    #    2|
    #    3|   int main() {
    #    4|->   return (int) adler32;
    #    5|   }

    Error: CLIPPY_WARNING: [#def2]
    bootc-202512190045.g72f1f2720d-build/crates/etc-merge/src/lib.rs:78:5: warning: unneeded `return` statement
    #     |
    #  78 |     return true;
    #     |     ^^^^^^^^^^^
    #     |
    #     = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#needless_return
    #     = note: `#[warn(clippy::needless_return)]` on by default
    #  help: remove `return`
    #     |
    #  78 -     return true;
    #  78 +     true
    #     |

    Error: CLIPPY_WARNING: [#def3]
    bootc-202512190045.g72f1f2720d-build/crates/etc-merge/src/lib.rs:295:5: warning: doc list item without indentation
    #      |
    #  295 | /// Usually this will be obtained by remounting the EROFS image to a temporary location
    #      |     ^
    #      |
    #      = help: if this is supposed to be its own paragraph, add a blank line
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#doc_lazy_continuation
    #      = note: `#[warn(clippy::doc_lazy_continuation)]` on by default
    #  help: indent this line
    #      |
    #  295 | ///   Usually this will be obtained by remounting the EROFS image to a temporary location
    #      |     ++

    Error: CLIPPY_WARNING: [#def4]
    bootc-202512190045.g72f1f2720d-build/crates/etc-merge/src/lib.rs:300:5: warning: doc list item without indentation
    #      |
    #  300 | /// again be usually obtained by mounting the new EROFS image to a temporary location. If merging
    #      |     ^
    #      |
    #      = help: if this is supposed to be its own paragraph, add a blank line
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#doc_lazy_continuation
    #  help: indent this line
    #      |
    #  300 | ///   again be usually obtained by mounting the new EROFS image to a temporary location. If merging
    #      |     ++

    Error: CLIPPY_WARNING: [#def5]
    bootc-202512190045.g72f1f2720d-build/crates/etc-merge/src/lib.rs:301:5: warning: doc list item without indentation
    #      |
    #  301 | /// it will be necessary to make the `/etc` for the deployment writeable
    #      |     ^
    #      |
    #      = help: if this is supposed to be its own paragraph, add a blank line
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#doc_lazy_continuation
    #  help: indent this line
    #      |
    #  301 | ///   it will be necessary to make the `/etc` for the deployment writeable
    #      |     ++

    Error: CLIPPY_WARNING: [#def6]
    bootc-202512190045.g72f1f2720d-build/crates/etc-merge/src/lib.rs:314:6: warning: very complex type used. Consider factoring parts into `type` definitions
    #      |
    #  314 |   ) -> anyhow::Result<(
    #      |  ______^
    #  315 | |     Directory<CustomMetadata>,
    #  316 | |     Directory<CustomMetadata>,
    #  317 | |     Option<Directory<CustomMetadata>>,
    #  318 | | )> {
    #      | |__^
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#type_complexity
    #      = note: `#[warn(clippy::type_complexity)]` on by default

    Error: CLIPPY_WARNING: [#def7]
    bootc-202512190045.g72f1f2720d-build/crates/etc-merge/src/lib.rs:338:5: warning: unneeded `return` statement
    #      |
    #  338 |     return Ok((pristine_etc_files, current_etc_files, new_etc_files));
    #      |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#needless_return
    #  help: remove `return`
    #      |
    #  338 -     return Ok((pristine_etc_files, current_etc_files, new_etc_files));
    #  338 +     Ok((pristine_etc_files, current_etc_files, new_etc_files))
    #      |

    Error: CLIPPY_WARNING: [#def8]
    bootc-202512190045.g72f1f2720d-build/crates/etc-merge/src/lib.rs:441:35: warning: useless use of `format!`
    #      |
    #  441 |         let entry = entry.context(format!("Getting entry"))?;
    #      |                                   ^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"Getting entry".to_string()`
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#useless_format
    #      = note: `#[warn(clippy::useless_format)]` on by default

    Error: CLIPPY_WARNING: [#def9]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/bootc_composefs/boot.rs:440:6: warning: very complex type used. Consider factoring parts into `type` definitions
    #      |
    #  440 | ) -> Result<Option<(String, Option<String>, Option<String>)>> {
    #      |      ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#type_complexity
    #      = note: `#[warn(clippy::type_complexity)]` on by default

    Error: CLIPPY_WARNING: [#def10]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/bootc_composefs/boot.rs:546:21: warning: useless conversion to the same type: `bootc_kernel_cmdline::utf8::Cmdline<'_>`
    #      |
    #  546 |                     Cmdline::from(options)
    #      |                     ^^^^^^^^^^^^^^^^^^^^^^ help: consider removing `Cmdline::from()`: `options`
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#useless_conversion
    #      = note: `#[warn(clippy::useless_conversion)]` on by default

    Error: CLIPPY_WARNING: [#def11]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/bootc_composefs/boot.rs:784:1: warning: this function has too many arguments (8/7)
    #      |
    #  784 | / fn write_pe_to_esp(
    #  785 | |     repo: &crate::store::ComposefsRepository,
    #  786 | |     file: &RegularFile<Sha512HashValue>,
    #  787 | |     file_path: &Utf8Path,
    #  ...   |
    #  792 | |     bootloader: &Bootloader,
    #  793 | | ) -> Result<Option<UKILabels>> {
    #      | |______________________________^
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#too_many_arguments
    #      = note: `#[warn(clippy::too_many_arguments)]` on by default

    Error: CLIPPY_WARNING: [#def12]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/bootc_composefs/boot.rs:875:29: warning: called `Iterator::last` on a `DoubleEndedIterator`; this will needlessly iterate the entire iterator
    #      |
    #  875 |           PEType::UkiAddon => file_path
    #      |  _____________________________^
    #  876 | |             .components()
    #  877 | |             .last()
    #      | |______________-----^
    #      |                |
    #      |                help: try: `next_back()`
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#double_ended_iterator_last
    #      = note: `#[warn(clippy::double_ended_iterator_last)]` on by default

    Error: CLIPPY_WARNING: [#def13]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/bootc_composefs/boot.rs:1104:38: warning: called `Iterator::last` on a `DoubleEndedIterator`; this will needlessly iterate the entire iterator
    #       |
    #  1104 |                       let addon_name = entry
    #       |  ______________________________________^
    #  1105 | |                         .file_path
    #  1106 | |                         .components()
    #  1107 | |                         .last()
    #       | |__________________________-----^
    #       |                            |
    #       |                            help: try: `next_back()`
    #       |
    #       = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#double_ended_iterator_last

    Error: CLIPPY_WARNING: [#def14]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/bootc_composefs/boot.rs:1201:5: warning: unneeded `return` statement
    #       |
    #  1201 | /     return Ok(Some(SecurebootKeys {
    #  1202 | |         dir: keys_dir,
    #  1203 | |         keys: entries,
    #  1204 | |     }));
    #       | |_______^
    #       |
    #       = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#needless_return
    #       = note: `#[warn(clippy::needless_return)]` on by default
    #  help: remove `return`
    #       |
    #  1201 ~     Ok(Some(SecurebootKeys {
    #  1202 +         dir: keys_dir,
    #  1203 +         keys: entries,
    #  1204 ~     }))
    #       |

    Error: CLIPPY_WARNING: [#def15]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/bootc_composefs/boot.rs:1250:23: warning: using `.iter().next()` on an array
    #       |
    #  1250 |     let Some(entry) = entries.iter().next() else {
    #       |                       ^^^^^^^^^^^^^^^^^^^^^ help: try calling: `entries.first()`
    #       |
    #       = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#iter_next_slice
    #       = note: `#[warn(clippy::iter_next_slice)]` on by default

    Error: CLIPPY_WARNING: [#def16]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/bootc_composefs/delete.rs:320:8: warning: taken reference of right operand
    #      |
    #  320 |     if deployment_id == &booted.verity {
    #      |        ^^^^^^^^^^^^^^^^^--------------
    #      |                         |
    #      |                         help: use the right value directly: `booted.verity`
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#op_ref
    #      = note: `#[warn(clippy::op_ref)]` on by default

    Error: CLIPPY_WARNING: [#def17]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/bootc_composefs/delete.rs:334:27: warning: this `map_or` can be simplified
    #      |
    #  334 |       let deleting_staged = host
    #      |  ___________________________^
    #  335 | |         .status
    #  336 | |         .staged
    #  337 | |         .as_ref()
    #  338 | |         .and_then(|s| s.composefs.as_ref())
    #  339 | |         .map_or(false, |cfs| cfs.verity == deployment_id);
    #      | |_________________________________________________________^
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#unnecessary_map_or
    #      = note: `#[warn(clippy::unnecessary_map_or)]` on by default
    #  help: use is_some_and instead
    #      |
    #  339 -         .map_or(false, |cfs| cfs.verity == deployment_id);
    #  339 +         .is_some_and(|cfs| cfs.verity == deployment_id);
    #      |

    Error: CLIPPY_WARNING: [#def18]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/bootc_composefs/repo.rs:77:16: warning: writing `&String` instead of `&str` involves a new object where a slice will do
    #     |
    #  77 |     transport: &String,
    #     |                ^^^^^^^ help: change this to: `&str`
    #     |
    #     = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#ptr_arg
    #     = note: `#[warn(clippy::ptr_arg)]` on by default

    Error: CLIPPY_WARNING: [#def19]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/bootc_composefs/repo.rs:78:12: warning: writing `&String` instead of `&str` involves a new object where a slice will do
    #     |
    #  78 |     image: &String,
    #     |            ^^^^^^^ help: change this to: `&str`
    #     |
    #     = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#ptr_arg

    Error: CLIPPY_WARNING: [#def20]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/bootc_composefs/status.rs:154:19: warning: slow zero-filling initialization
    #      |
    #  154 |       let mut buf = Vec::with_capacity(manifest.config().size() as usize);
    #      |  ___________________^
    #  155 | |     buf.resize(manifest.config().size() as usize, 0);
    #      | |____________________________________________________^ help: consider replacing this with: `vec![0; manifest.config().size() as usize]`
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#slow_vector_initialization
    #      = note: `#[warn(clippy::slow_vector_initialization)]` on by default

    Error: CLIPPY_WARNING: [#def21]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/bootc_composefs/update.rs:103:5: warning: doc list item overindented
    #      |
    #  103 | ///    /run/composefs/staged-deployment which is the last thing we create while upgrading
    #      |     ^^^ help: try using `  ` (2 spaces)
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#doc_overindented_list_items
    #      = note: `#[warn(clippy::doc_overindented_list_items)]` on by default

    Error: CLIPPY_WARNING: [#def22]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/bootc_composefs/update.rs:108:5: warning: doc list item overindented
    #      |
    #  108 | ///    point
    #      |     ^^^ help: try using `  ` (2 spaces)
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#doc_overindented_list_items

    Error: CLIPPY_WARNING: [#def23]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/bootc_composefs/update.rs:113:5: warning: doc list item overindented
    #      |
    #  113 | ///    was created, or at any other point in time, or it's a new one.
    #      |     ^^^ help: try using `  ` (2 spaces)
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#doc_overindented_list_items

    Error: CLIPPY_WARNING: [#def24]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/bootc_composefs/update.rs:114:5: warning: doc list item overindented
    #      |
    #  114 | ///    Any which way, we can overwrite everything
    #      |     ^^^ help: try using `  ` (2 spaces)
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#doc_overindented_list_items

    Error: CLIPPY_WARNING: [#def25]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/bootc_composefs/update.rs:223:23: warning: using `.iter().next()` on an array
    #      |
    #  223 |     let Some(entry) = entries.iter().next() else {
    #      |                       ^^^^^^^^^^^^^^^^^^^^^ help: try calling: `entries.first()`
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#iter_next_slice

    Error: CLIPPY_WARNING: [#def26]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/bootc_composefs/update.rs:379:34: warning: deref which would be done by auto-deref
    #      |
    #  379 |             get_imginfo(storage, &*composefs.cmdline.digest, booted_imgref).await?;
    #      |                                  ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `&composefs.cmdline.digest`
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#explicit_auto_deref
    #      = note: `#[warn(clippy::explicit_auto_deref)]` on by default

    Error: CLIPPY_WARNING: [#def27]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/cli.rs:1121:5: warning: unneeded `return` statement
    #       |
    #  1121 |     return Ok(target);
    #       |     ^^^^^^^^^^^^^^^^^
    #       |
    #       = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#needless_return
    #  help: remove `return`
    #       |
    #  1121 -     return Ok(target);
    #  1121 +     Ok(target)
    #       |

    Error: CLIPPY_WARNING: [#def28]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/deploy.rs:785:13: warning: field assignment outside of initializer for an instance created with Default::default()
    #      |
    #  785 |             opts.locked = lock_finalization;
    #      |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    #      |
    #  note: consider initializing the variable with `SysrootDeployTreeOpts::<'_> { locked: lock_finalization, ..Default::default() }` and removing relevant reassignments
    #     --> crates/lib/src/deploy.rs:782:13
    #      |
    #  782 |             let mut opts = ostree::SysrootDeployTreeOpts::default();
    #      |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#field_reassign_with_default
    #      = note: `#[warn(clippy::field_reassign_with_default)]` on by default

    Error: CLIPPY_WARNING: [#def29]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/install.rs:668:16: warning: inequality checks against false are unnecessary
    #      |
    #  668 |             if self.composefs_opts.insecure != false {
    #      |                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `self.composefs_opts.insecure`
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#bool_comparison
    #      = note: `#[warn(clippy::bool_comparison)]` on by default

    Error: CLIPPY_WARNING: [#def30]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/install.rs:1527:20: warning: this `else { if .. }` block can be collapsed
    #       |
    #  1527 |               } else {
    #       |  ____________________^
    #  1528 | |                 if crate::bootloader::supports_bootupd(d)? {
    #  1529 | |                     crate::spec::Bootloader::Grub
    #  1530 | |                 } else {
    #  ...    |
    #  1533 | |             }
    #       | |_____________^
    #       |
    #       = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#collapsible_else_if
    #       = note: `#[warn(clippy::collapsible_else_if)]` on by default
    #  help: collapse nested if block
    #       |
    #  1527 ~             } else if crate::bootloader::supports_bootupd(d)? {
    #  1528 +                 crate::spec::Bootloader::Grub
    #  1529 +             } else {
    #  1530 +                 crate::spec::Bootloader::Systemd
    #  1531 +             }
    #       |

    Error: CLIPPY_WARNING: [#def31]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/install.rs:1748:24: warning: called `.as_ref().map(|s| s.as_str())` on an `Option` value
    #       |
    #  1748 |       let source_image = opts
    #       |  ________________________^
    #  1749 | |         .source_opts
    #  1750 | |         .source_imgref
    #  1751 | |         .as_ref()
    #  1752 | |         .map(|s| s.as_str())
    #       | |____________________________^
    #       |
    #       = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#option_as_ref_deref
    #       = note: `#[warn(clippy::option_as_ref_deref)]` on by default
    #  help: consider using as_deref
    #       |
    #  1748 ~     let source_image = opts
    #  1749 +         .source_opts
    #  1750 +         .source_imgref.as_deref()
    #       |

    Error: CLIPPY_WARNING: [#def32]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/install.rs:2036:24: warning: called `.as_ref().map(|s| s.as_str())` on an `Option` value
    #       |
    #  2036 |       let source_image = opts
    #       |  ________________________^
    #  2037 | |         .source_opts
    #  2038 | |         .source_imgref
    #  2039 | |         .as_ref()
    #  2040 | |         .map(|s| s.as_str())
    #       | |____________________________^
    #       |
    #       = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#option_as_ref_deref
    #  help: consider using as_deref
    #       |
    #  2036 ~     let source_image = opts
    #  2037 +         .source_opts
    #  2038 +         .source_imgref.as_deref()
    #       |

    Error: CLIPPY_WARNING: [#def33]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/install.rs:2303:24: warning: called `.as_ref().map(|s| s.as_str())` on an `Option` value
    #       |
    #  2303 |       let source_image = opts
    #       |  ________________________^
    #  2304 | |         .source_opts
    #  2305 | |         .source_imgref
    #  2306 | |         .as_ref()
    #  2307 | |         .map(|s| s.as_str())
    #       | |____________________________^
    #       |
    #       = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#option_as_ref_deref
    #  help: consider using as_deref
    #       |
    #  2303 ~     let source_image = opts
    #  2304 +         .source_opts
    #  2305 +         .source_imgref.as_deref()
    #       |

    Error: CLIPPY_WARNING: [#def34]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/lints.rs:763:43: warning: useless conversion to the same type: `cap_std_ext::cap_std::fs::ReadDir`
    #      |
    #  763 |       let entries: Result<BTreeSet<_>, _> = d
    #      |  ___________________________________________^
    #  764 | |         .entries()?
    #  765 | |         .into_iter()
    #      | |____________________^
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#useless_conversion
    #  help: consider removing `.into_iter()`
    #      |
    #  763 ~     let entries: Result<BTreeSet<_>, _> = d
    #  764 +         .entries()?
    #      |

    Error: CLIPPY_WARNING: [#def35]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/parsers/bls_config.rs:20:5: warning: name `EFI` contains a capitalized acronym
    #     |
    #  20 |     EFI {
    #     |     ^^^ help: consider making the acronym lowercase, except the initial letter (notice the capitalization): `Efi`
    #     |
    #     = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#upper_case_acronyms
    #     = note: `#[warn(clippy::upper_case_acronyms)]` on by default

    Error: CLIPPY_WARNING: [#def36]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/parsers/bls_config.rs:176:46: warning: called `Iterator::last` on a `DoubleEndedIterator`; this will needlessly iterate the entire iterator
    #      |
    #  176 |               BLSConfigType::EFI { efi } => Ok(efi
    #      |  ______________________________________________^
    #  177 | |                 .components()
    #  178 | |                 .last()
    #      | |__________________-----^
    #      |                    |
    #      |                    help: try: `next_back()`
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#double_ended_iterator_last

    Error: CLIPPY_WARNING: [#def37]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/parsers/grub_menuconfig.rs:109:12: warning: called `Iterator::last` on a `DoubleEndedIterator`; this will needlessly iterate the entire iterator
    #      |
    #  109 |           Ok(to_path
    #      |  ____________^
    #  110 | |             .components()
    #  111 | |             .last()
    #      | |______________-----^
    #      |                |
    #      |                help: try: `next_back()`
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#double_ended_iterator_last

    Error: CLIPPY_WARNING: [#def38]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/parsers/grub_menuconfig.rs:134:22: warning: redundant guard
    #      |
    #  134 |                 c if c == '\\' => {
    #      |                      ^^^^^^^^^
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#redundant_guards
    #      = note: `#[warn(clippy::redundant_guards)]` on by default
    #  help: try
    #      |
    #  134 -                 c if c == '\\' => {
    #  134 +                 '\\' => {
    #      |

    Error: CLIPPY_WARNING: [#def39]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/podstorage.rs:159:35: warning: the following explicit lifetimes could be elided: 'c
    #      |
    #  159 | pub fn set_additional_image_store<'c>(
    #      |                                   ^^
    #  160 |     cmd: &'c mut Command,
    #      |           ^^
    #  161 |     ais: impl AsRef<Utf8Path>,
    #  162 | ) -> &'c mut Command {
    #      |       ^^
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#needless_lifetimes
    #      = note: `#[warn(clippy::needless_lifetimes)]` on by default
    #  help: elide the lifetimes
    #      |
    #  159 ~ pub fn set_additional_image_store(
    #  160 ~     cmd: &mut Command,
    #  161 |     ais: impl AsRef<Utf8Path>,
    #  162 ~ ) -> &mut Command {
    #      |

    Error: CLIPPY_WARNING: [#def40]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/utils.rs:247:13: warning: unneeded `return` statement
    #      |
    #  247 |             return Ok(loader);
    #      |             ^^^^^^^^^^^^^^^^^
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#needless_return
    #  help: remove `return`
    #      |
    #  247 -             return Ok(loader);
    #  247 +             Ok(loader)
    #      |

    Error: CLIPPY_WARNING: [#def41]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/utils.rs:251:13: warning: unneeded `return` statement
    #      |
    #  251 |             return Err(EfiError::MissingVar);
    #      |             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#needless_return
    #  help: remove `return`
    #      |
    #  251 -             return Err(EfiError::MissingVar);
    #  251 +             Err(EfiError::MissingVar)
    #      |

    Error: CLIPPY_WARNING: [#def42]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/utils.rs:271:14: warning: this `repeat().take()` can be written more concisely
    #      |
    #  271 |     let up = std::iter::repeat(Component::ParentDir).take(from.len() - common);
    #      |              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `repeat_n()` instead: `std::iter::repeat_n(Component::ParentDir, from.len() - common)`
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#manual_repeat_n
    #      = note: `#[warn(clippy::manual_repeat_n)]` on by default

    Error: CLIPPY_WARNING: [#def43]
    bootc-202512190045.g72f1f2720d-build/crates/lib/src/utils.rs:277:5: warning: unneeded `return` statement
    #      |
    #  277 |     return Ok(final_path);
    #      |     ^^^^^^^^^^^^^^^^^^^^^
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#needless_return
    #  help: remove `return`
    #      |
    #  277 -     return Ok(final_path);
    #  277 +     Ok(final_path)
    #      |

    Error: CLIPPY_WARNING: [#def44]
    bootc-202512190045.g72f1f2720d-build/crates/ostree-ext/src/container/store.rs:945:5: warning: this function has too many arguments (10/7)
    #      |
    #  945 | /     fn write_merge_commit_impl(
    #  946 | |         repo: &ostree::Repo,
    #  947 | |         base_commit: Option<&str>,
    #  948 | |         layer_commits: &[String],
    #  ...   |
    #  955 | |         cancellable: Option<&gio::Cancellable>,
    #  956 | |     ) -> Result<Box<LayeredImageState>> {
    #      | |_______________________________________^
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#too_many_arguments
    #      = note: `#[warn(clippy::too_many_arguments)]` on by default

    Error: CLIPPY_WARNING: [#def45]
    bootc-202512190045.g72f1f2720d-build/crates/ostree-ext/src/container/store.rs:1044:22: warning: derefed type is same as origin
    #       |
    #  1044 |         let parent = base_commit.as_deref();
    #       |                      ^^^^^^^^^^^^^^^^^^^^^^ help: try: `base_commit`
    #       |
    #       = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#needless_option_as_deref
    #       = note: `#[warn(clippy::needless_option_as_deref)]` on by default

    Error: CLIPPY_WARNING: [#def46]
    bootc-202512190045.g72f1f2720d-build/crates/ostree-ext/src/container/store.rs:1580:36: warning: using `clone` on type `Option<&History>` which implements the `Copy` trait
    #       |
    #  1580 |           let previous_description = history_entry
    #       |  ____________________________________^
    #  1581 | |             .clone()
    #       | |____________________^ help: try removing the `clone` call: `history_entry`
    #       |
    #       = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#clone_on_copy
    #       = note: `#[warn(clippy::clone_on_copy)]` on by default

    Error: CLIPPY_WARNING: [#def47]
    bootc-202512190045.g72f1f2720d-build/crates/ostree-ext/src/ostree_prepareroot.rs:105:1: warning: this `impl` can be derived
    #      |
    #  105 | / impl Default for Tristate {
    #  106 | |     fn default() -> Self {
    #  107 | |         Self::Disabled
    #  108 | |     }
    #  109 | | }
    #      | |_^
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#derivable_impls
    #      = note: `#[warn(clippy::derivable_impls)]` on by default
    #  help: replace the manual implementation with a derive attribute and mark the default variant
    #      |
    #   81 + #[derive(Default)]
    #   82 | pub enum Tristate {
    #   83 |     /// Enabled
    #   84 |     Enabled,
    #   85 |     /// Disabled
    #   86 ~     #[default]
    #   87 ~     Disabled,
    #      |

    Error: CLIPPY_WARNING: [#def48]
    bootc-202512190045.g72f1f2720d-build/crates/ostree-ext/src/sysroot.rs:107:5: warning: this `let...else` may be rewritten with the `?` operator
    #      |
    #  107 | /     let Some(statename) = name.strip_prefix(AUTO_STATEROOT_PREFIX) else {
    #  108 | |         return None;
    #  109 | |     };
    #      | |______^ help: replace it with: `let statename = name.strip_prefix(AUTO_STATEROOT_PREFIX)?;`
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#question_mark
    #      = note: `#[warn(clippy::question_mark)]` on by default

    Error: CLIPPY_WARNING: [#def49]
    bootc-202512190045.g72f1f2720d-build/crates/ostree-ext/src/sysroot.rs:110:5: warning: this `let...else` may be rewritten with the `?` operator
    #      |
    #  110 | /     let Some((year, serial)) = statename.split_once("-") else {
    #  111 | |         return None;
    #  112 | |     };
    #      | |______^ help: replace it with: `let (year, serial) = statename.split_once("-")?;`
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#question_mark

    Error: CLIPPY_WARNING: [#def50]
    bootc-202512190045.g72f1f2720d-build/crates/tests-integration/src/container.rs:100:5: warning: matching on `Some` with `ok()` is redundant
    #      |
    #  100 |     if let Some(variant) = std::env::var("BOOTC_variant").ok() {
    #      |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#match_result_ok
    #      = note: `#[warn(clippy::match_result_ok)]` on by default
    #  help: consider matching on `Ok(variant)` and removing the call to `ok` instead
    #      |
    #  100 -     if let Some(variant) = std::env::var("BOOTC_variant").ok() {
    #  100 +     if let Ok(variant) = std::env::var("BOOTC_variant") {
    #      |

    Error: CLIPPY_WARNING: [#def51]
    bootc-202512190045.g72f1f2720d-build/crates/tests-integration/src/container.rs:113:5: warning: matching on `Some` with `ok()` is redundant
    #      |
    #  113 |     if let Some(base) = std::env::var("BOOTC_base").ok() {
    #      |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#match_result_ok
    #  help: consider matching on `Ok(base)` and removing the call to `ok` instead
    #      |
    #  113 -     if let Some(base) = std::env::var("BOOTC_base").ok() {
    #  113 +     if let Ok(base) = std::env::var("BOOTC_base") {
    #      |

    Error: CLIPPY_WARNING: [#def52]
    bootc-202512190045.g72f1f2720d-build/crates/tests-integration/src/container.rs:162:16: warning: use of a disallowed method `str::len`
    #      |
    #  162 |         digest.len(),
    #      |                ^^^
    #      |
    #      = note: use <str>.as_bytes().len() instead
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#disallowed_methods
    #      = note: requested on the command line with `-D clippy::disallowed-methods`

    Error: CLIPPY_WARNING: [#def53]
    bootc-202512190045.g72f1f2720d-build/crates/tests-integration/src/container.rs:165:16: warning: use of a disallowed method `str::len`
    #      |
    #  165 |         digest.len()
    #      |                ^^^
    #      |
    #      = note: use <str>.as_bytes().len() instead
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#disallowed_methods

    Error: CLIPPY_WARNING: [#def54]
    bootc-202512190045.g72f1f2720d-build/crates/xtask/src/man.rs:309:13: warning: returning the result of a `let` binding from a block
    #      |
    #  308 |             let path = find_command_path_for_filename(cli_structure, cmd_part);
    #      |             ------------------------------------------------------------------- unnecessary `let` binding
    #  309 |             path
    #      |             ^^^^
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#let_and_return
    #      = note: `#[warn(clippy::let_and_return)]` on by default
    #  help: return the expression directly
    #      |
    #  308 ~
    #  309 ~             find_command_path_for_filename(cli_structure, cmd_part)
    #      |

    Error: CLIPPY_WARNING: [#def55]
    bootc-202512190045.g72f1f2720d-build/crates/xtask/src/man.rs:606:5: warning: empty string literal in `println!`
    #      |
    #  606 |     println!("");
    #      |     ^^^^^^^^^--^
    #      |              |
    #      |              help: remove the empty string
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#println_empty_string
    #      = note: `#[warn(clippy::println_empty_string)]` on by default

    Error: CLIPPY_WARNING: [#def56]
    bootc-202512190045.g72f1f2720d-build/crates/xtask/src/man.rs:622:12: warning: this `map_or` can be simplified
    #      |
    #  622 |           if path
    #      |  ____________^
    #  623 | |             .extension()
    #  624 | |             .and_then(|s| s.to_str())
    #  625 | |             .map_or(false, |e| e.chars().all(|c| c.is_numeric()))
    #      | |_________________________________________________________________^
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#unnecessary_map_or
    #      = note: `#[warn(clippy::unnecessary_map_or)]` on by default
    #  help: use is_some_and instead
    #      |
    #  625 -             .map_or(false, |e| e.chars().all(|c| c.is_numeric()))
    #  625 +             .is_some_and(|e| e.chars().all(|c| c.is_numeric()))
    #      |

    Error: CLIPPY_WARNING: [#def57]
    bootc-202512190045.g72f1f2720d-build/crates/xtask/src/tmt.rs:277:32: warning: useless use of `format!`
    #      |
    #  277 |         .chain(std::iter::once(format!("--context=running_env=image_mode")))
    #      |                                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `.to_string()`: `"--context=running_env=image_mode".to_string()`
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#useless_format
    #      = note: `#[warn(clippy::useless_format)]` on by default

    Error: CLIPPY_WARNING: [#def58]
    bootc-202512190045.g72f1f2720d-build/crates/xtask/src/tmt.rs:935:5: warning: calling `push_str()` using a single-character string literal
    #      |
    #  935 |     tests_content.push_str("\n");
    #      |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider using `push` with a character literal: `tests_content.push('\n')`
    #      |
    #      = help: for further information visit https://rust-lang.github.io/rust-clippy/rust-1.92.0/index.html#single_char_add_str
    #      = note: `#[warn(clippy::single_char_add_str)]` on by default

## Scan Properties

analyzer-version-clippy | 1.92.0
analyzer-version-cppcheck | 2.18.3
analyzer-version-gcc | 15.2.1
analyzer-version-gcc-analyzer | 15.2.1
analyzer-version-shellcheck | 0.11.0
analyzer-version-unicontrol | 0.0.2
diffbase-analyzer-version-clippy | 1.92.0
diffbase-analyzer-version-cppcheck | 2.18.3
diffbase-analyzer-version-gcc | 15.2.1
diffbase-analyzer-version-gcc-analyzer | 15.2.1
diffbase-analyzer-version-shellcheck | 0.11.0
diffbase-analyzer-version-unicontrol | 0.0.2
diffbase-enabled-plugins | clippy, cppcheck, gcc, shellcheck, unicontrol
diffbase-exit-code | 0
diffbase-host | ip-172-16-1-142.us-west-2.compute.internal
diffbase-known-false-positives | /usr/share/csmock/known-false-positives.js
diffbase-known-false-positives-rpm | known-false-positives-0.0.0.20250521.132812.g8eff701.main-1.el9.noarch
diffbase-mock-config | fedora-rawhide-x86_64
diffbase-project-name | bootc-202512190045.g72f1f2720d-1
diffbase-store-results-to | /tmp/tmpxl3oirhx/bootc-202512190045.g72f1f2720d-1.tar.xz
diffbase-time-created | 2025-12-19 02:31:47
diffbase-time-finished | 2025-12-19 02:45:50
diffbase-tool | csmock
diffbase-tool-args | '/usr/bin/csmock' '-r' 'fedora-rawhide-x86_64' '-t' 'cppcheck,unicontrol,gcc,shellcheck,clippy' '-o' '/tmp/tmpxl3oirhx/bootc-202512190045.g72f1f2720d-1.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install' 'pam' '/tmp/tmpxl3oirhx/bootc-202512190045.g72f1f2720d-1.src.rpm'
diffbase-tool-version | csmock-3.8.3.20251215.161544.g62de9a5-1.el9
enabled-plugins | clippy, cppcheck, gcc, shellcheck, unicontrol
exit-code | 0
host | ip-172-16-1-142.us-west-2.compute.internal
known-false-positives | /usr/share/csmock/known-false-positives.js
known-false-positives-rpm | known-false-positives-0.0.0.20250521.132812.g8eff701.main-1.el9.noarch
mock-config | fedora-rawhide-x86_64
project-name | bootc-202512190045.g72f1f2720d-1
store-results-to | /tmp/tmpxl3oirhx/bootc-202512190045.g72f1f2720d-1.tar.xz
time-created | 2025-12-19 02:31:47
time-finished | 2025-12-19 02:45:50
tool | csmock
tool-args | '/usr/bin/csmock' '-r' 'fedora-rawhide-x86_64' '-t' 'cppcheck,unicontrol,gcc,shellcheck,clippy' '-o' '/tmp/tmpxl3oirhx/bootc-202512190045.g72f1f2720d-1.tar.xz' '--gcc-analyze' '--unicontrol-notests' '--unicontrol-bidi-only' '--install' 'pam' '/tmp/tmpxl3oirhx/bootc-202512190045.g72f1f2720d-1.src.rpm'
tool-version | csmock-3.8.3.20251215.161544.g62de9a5-1.el9