add exit code to shutdown
Merge pull request #276 from DavidZey/processExit

add exit code to shutdown