Fix suspend-during-shutdown issue

We go out of our way to avoid suspending if the lid is closed and a
shutdown or reboot is already in progress by recording the fact that
we're shutting down into a static variable and ignoring suspend requests
if this variable is set.

Unfortunately, during long shutdowns, this conflicts with our exiting
after 10 seconds of inactivity.  If the suspend request is more than 10
seconds after the shutdown request then systemd-shim will have quit and
the 'in_shutdown' variable will be false again in the newly-activated
process.

Deal with this by preventing systemd-shim from exiting while the system
is shutting down.