~bzr-pqm/bzr/bzr.dev

Viewing all changes in revision 5247.5.7.

  • Committer: Vincent Ladeuil
  • Date: 2010-06-07 14:25:19 UTC
  • mto: (5247.6.1 http-leaks)
  • mto: This revision was merged to the branch mainline in revision 5396.
  • Revision ID: v.ladeuil+lp@free.fr-20100607142519-d37kawz1w1btjym3
Factor out socket exception handling during server shutdown.

* bzrlib/tests/test_server.py:
(TestingTCPServerMixin.ignored_exceptions_during_shutdown): Factor
out the exceptions that can occur during server shutdown. This
should be used both for the server and client connections threads
as well as the main thread itself (since the socket exception can
be raised in any thread, at least on windows).
(TestingTCPServerMixin.shutdown_client_socket): Simplified.
(TestingTCPServerInAThread.stop_server): Install the exception handler.

expand all expand all

Show diffs side-by-side

added added

removed removed

Lines of Context: