Hack in exit code detection
(of sorts)