Skip to content

Commit 5b9332c

Browse files
committed
chromium_mod: Don't crash on ctrl+c in UEFI
Signed-off-by: Daniel Schaefer <[email protected]>
1 parent 1ff0e04 commit 5b9332c

File tree

1 file changed

+5
-1
lines changed
  • framework_lib/src/chromium_ec

1 file changed

+5
-1
lines changed

framework_lib/src/chromium_ec/mod.rs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -545,7 +545,11 @@ impl CrosEc {
545545
for chunk_no in 0..chunks {
546546
#[cfg(feature = "uefi")]
547547
if shell_get_execution_break_flag() {
548-
return Err(EcError::DeviceError("Execution interrupted".to_string()));
548+
// TODO: We don't want to crash here. But returning no data doesn't seem optimal
549+
// either
550+
// return Err(EcError::DeviceError("Execution interrupted".to_string()));
551+
println!("Execution interrupted");
552+
return Ok(vec![]);
549553
}
550554

551555
let offset = offset + chunk_no * chunk_size;

0 commit comments

Comments
 (0)