Ensure systems recovery actions can happen.
In Windows versions earlier than Vista the service manager would only
consider a service failed (and hence eligible for recovery action) if
the service exited without setting its state to SERVICE_STOPPED, even if
it signalled an error exit code.
In Vista and later the service manager can be configured to treat a
graceful shutdown with error code as a failure but this is not the
default behaviour.
Try to configure the service manager to use the new behaviour when
starting the service so users who set AppExit to Exit can use recovery
actions as expected.
Also recognise the new AppExit option Suicide for use on pre-Vista
systems. When AppExit is Suicide don't stop the service but exit
inelegantly, which should be seen as a failure.