diff options
Diffstat (limited to 'remuxer/src/seek_index.rs')
-rw-r--r-- | remuxer/src/seek_index.rs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/remuxer/src/seek_index.rs b/remuxer/src/seek_index.rs index 9204a51..68ccb4a 100644 --- a/remuxer/src/seek_index.rs +++ b/remuxer/src/seek_index.rs @@ -3,7 +3,7 @@ which is licensed under the GNU Affero General Public License (version 3); see /COPYING. Copyright (C) 2023 metamuffin <metamuffin.org> */ -use anyhow::Result; +use anyhow::{Context, Result}; use jellybase::cache::cache_memory; use jellycommon::seek_index::{BlockIndex, SeekIndex}; use jellymatroska::{ @@ -18,7 +18,7 @@ use std::{collections::BTreeMap, fs::File, path::Path, sync::Arc}; pub fn get_seek_index(path: &Path) -> anyhow::Result<Arc<BTreeMap<u64, Arc<SeekIndex>>>> { cache_memory(&["seekindex", path.to_str().unwrap()], move || { info!("generating seek index for {path:?}"); - let input = File::open(&path).unwrap(); + let input = File::open(&path).context("opening source file")?; let mut input = EbmlReader::new(input); let index = import_seek_index(&mut input)?; info!("done"); |