]> git.lizzy.rs Git - rust.git/commitdiff
do not panic just because cargo failed
authorRalf Jung <post@ralfj.de>
Sun, 11 Nov 2018 09:43:33 +0000 (10:43 +0100)
committerRalf Jung <post@ralfj.de>
Sun, 11 Nov 2018 09:43:33 +0000 (10:43 +0100)
src/bootstrap/compile.rs

index cef0849937bf01861602cc947e48c63e562b2fc5..71b204b2de985e9e02edff2efcb67e416b871934 100644 (file)
@@ -22,7 +22,7 @@
 use std::io::BufReader;
 use std::io::prelude::*;
 use std::path::{Path, PathBuf};
-use std::process::{Command, Stdio};
+use std::process::{Command, Stdio, exit};
 use std::str;
 
 use build_helper::{output, mtime, up_to_date};
@@ -1098,7 +1098,7 @@ pub fn run_cargo(builder: &Builder,
     });
 
     if !ok {
-        panic!("cargo must succeed");
+        exit(1);
     }
 
     // Ok now we need to actually find all the files listed in `toplevel`. We've