catch signals while connections are being opened

Previously, signals were only handled after all connections had been
initialized.  This meant that mcmd couldn't be interrupted while trying
to connect to slow hosts.