From b15e5923ab5c02d9bfcfbe6c7d3666fcd85b1681 Mon Sep 17 00:00:00 2001 From: Rob Bradford Date: Sun, 24 Mar 2024 18:13:02 +0000 Subject: [PATCH] block: vhdx: "signature" field is unused Prefix field with an _ to indicate that this is intentionally unused. This resolved a nightly compiler check issue due to the unusued field. Signed-off-by: Rob Bradford --- block/src/vhdx/vhdx_header.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/block/src/vhdx/vhdx_header.rs b/block/src/vhdx/vhdx_header.rs index b21f7a0c2..40031c8ca 100644 --- a/block/src/vhdx/vhdx_header.rs +++ b/block/src/vhdx/vhdx_header.rs @@ -90,7 +90,7 @@ pub type Result = std::result::Result; #[derive(Clone, Debug)] pub struct FileTypeIdentifier { - pub signature: u64, + pub _signature: u64, } impl FileTypeIdentifier { @@ -98,14 +98,14 @@ impl FileTypeIdentifier { pub fn new(f: &mut File) -> Result { f.seek(SeekFrom::Start(FILE_START)) .map_err(VhdxHeaderError::SeekFileTypeIdentifier)?; - let signature = f + let _signature = f .read_u64::() .map_err(VhdxHeaderError::ReadFileTypeIdentifier)?; - if signature != VHDX_SIGN { + if _signature != VHDX_SIGN { return Err(VhdxHeaderError::InvalidVHDXSign); } - Ok(FileTypeIdentifier { signature }) + Ok(FileTypeIdentifier { _signature }) } }