Fixing MISO error codes

I am writing some wrapper scripts to run MISO. However, when you supply bad arguments MISO exits but with error code 0. So it is hard to check that the execution was successful. So I went through the main() function and changed lines like