summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--rust-src/mount/src/filesystem.rs5
1 files changed, 5 insertions, 0 deletions
diff --git a/rust-src/mount/src/filesystem.rs b/rust-src/mount/src/filesystem.rs
index b1575c26..89865bc4 100644
--- a/rust-src/mount/src/filesystem.rs
+++ b/rust-src/mount/src/filesystem.rs
@@ -195,11 +195,16 @@ pub fn probe_filesystems() -> anyhow::Result<HashMap<Uuid, FileSystem>> {
// #[tracing_attributes::instrument(skip(dev, fs_map))]
fn get_super_block_uuid(path: &std::path::Path) -> std::io::Result<std::io::Result<(Uuid, bcachefs::bch_sb_handle)>> {
+ use gag::{BufferRedirect};
+ // Stop libbcachefs from spamming the output
+ let gag = BufferRedirect::stdout().unwrap();
+
let sb = bch_bindgen::rs::read_super(&path)?;
let super_block = match sb {
Err(e) => { return Ok(Err(e)); }
Ok(sb) => sb,
};
+ drop(gag);
let uuid = (&super_block).sb().uuid();
tracing::debug!(found="bcachefs superblock", devnode=?path, ?uuid);