From 25bce91b4bdcc37d063ba22081007c1ef76355d6 Mon Sep 17 00:00:00 2001 From: Thomas Mühlbacher Date: Thu, 30 May 2024 20:50:00 +0200 Subject: refactor: rename function again MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit `bch2_sb_is_encrypted_and_locked()` simply does not check if the fs is locked. The name is misleading. Signed-off-by: Thomas Mühlbacher --- src/commands/mount.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/commands/mount.rs b/src/commands/mount.rs index 7f5937d0..f6254366 100644 --- a/src/commands/mount.rs +++ b/src/commands/mount.rs @@ -344,7 +344,7 @@ fn cmd_mount_inner(opt: Cli) -> anyhow::Result<()> { .unwrap(); // Check if the filesystem's master key is encrypted and we don't have a key - if unsafe { bcachefs::bch2_sb_is_encrypted_and_locked(block_devices_to_mount[0].sb) } + if unsafe { bcachefs::bch2_sb_is_encrypted(block_devices_to_mount[0].sb) } && !key::check_for_key(&key_name)? { // First by password_file, if available -- cgit v1.2.3