1
0
mirror of https://github.com/sharkdp/bat synced 2026-06-09 10:03:18 +00:00

Merge pull request #3609 from Nicolas0315/fix/builtin-pager-drop-panic

Fix panic in BuiltinPager Drop when pager thread fails (#3449)
This commit is contained in:
Keith Hall
2026-03-02 04:57:37 +02:00
committed by GitHub
+2 -2
View File
@@ -225,8 +225,8 @@ impl Drop for OutputType {
let _ = command.wait();
}
OutputType::BuiltinPager(ref mut pager) => {
if pager.handle.is_some() {
let _ = pager.handle.take().unwrap().join().unwrap();
if let Some(handle) = pager.handle.take() {
let _ = handle.join();
}
}
OutputType::Stdout(_) => (),