Replacing sys.exit calls with integer values.
Values correspond to /etc/init.d/skeleton on Ubuntu.