Fixing a potential busy-loop in mqexec/mqexec refactoring

There was a case where the socket monitor socket wouldn't get
unregistered from libev if heartbeats were enabled, and mqexec
would get caught in a mostly-busy-loop trying to read from
a now closed zeromq socket.

There were also a bunch of places where the logic of mqexec wasn't
quite clear - so this commit adds lots of comments.

Timed out children of mqexec now get killed with SIGTERM instead
of SIGKILL, so they can catch SIGTERM and cleanup gracefully if
they want to.

The reset_sockets_on_error option has been removed, because its
behavior was somewhat ambiguous, and using heartbeats is a much
cleaner solution anyway.