web: Assume SIGABRT is OOM

This commit is contained in:
Tiffany Bennett 2016-10-04 20:35:08 -04:00
parent 50c8a1045c
commit 73951c7b21

View file

@ -71,6 +71,8 @@ pub fn eval(query: &str) -> String {
};
match output.status.signal() {
Some(libc::SIGXCPU) => return format!("Calculation went over time limit"),
// SIGABRT doesn't necessarily mean OOM, but GMP will raise it when it happens
Some(libc::SIGABRT) => return format!("Calculation ran out of memory"),
_ => ()
};
format!(