~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/transport/ssh.py

  • Committer: Robert Collins
  • Date: 2010-02-27 12:27:33 UTC
  • mto: This revision was merged to the branch mainline in revision 5061.
  • Revision ID: robertc@robertcollins.net-20100227122733-2o3me3fkk3pk36ns
``bzrlib.branchbuilder.BranchBuilder.build_snapshot`` now accepts a
``message_callback`` in the same way that commit does. (Robert Collins)

Show diffs side-by-side

added added

removed removed

Lines of Context:
173
173
register_ssh_vendor = _ssh_vendor_manager.register_vendor
174
174
 
175
175
 
176
 
def _ignore_signals():
 
176
def _ignore_sigint():
177
177
    # TODO: This should possibly ignore SIGHUP as well, but bzr currently
178
178
    # doesn't handle it itself.
179
179
    # <https://launchpad.net/products/bzr/+bug/41433/+index>
180
180
    import signal
181
181
    signal.signal(signal.SIGINT, signal.SIG_IGN)
182
 
    # GZ 2010-02-19: Perhaps make this check if breakin is installed instead
183
 
    if signal.getsignal(signal.SIGQUIT) != signal.SIG_DFL:
184
 
        signal.signal(signal.SIGQUIT, signal.SIG_IGN)
185
182
 
186
183
 
187
184
class SocketAsChannelAdapter(object):
637
634
        # Running it in a separate process group is not good because then it
638
635
        # can't get non-echoed input of a password or passphrase.
639
636
        # <https://launchpad.net/products/bzr/+bug/40508>
640
 
        return {'preexec_fn': _ignore_signals,
 
637
        return {'preexec_fn': _ignore_sigint,
641
638
                'close_fds': True,
642
639
                }
643
640