~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/transport/ftp/__init__.py

  • Committer: Canonical.com Patch Queue Manager
  • Date: 2010-08-30 07:47:38 UTC
  • mfrom: (5394.2.1 integration2)
  • Revision ID: pqm@pqm.ubuntu.com-20100830074738-ymqwum541fi8b4sr
(vila) Fix most of the leaking tests (Vincent Ladeuil)

Show diffs side-by-side

added added

removed removed

Lines of Context:
170
170
        connection, credentials = self._create_connection(credentials)
171
171
        self._set_connection(connection, credentials)
172
172
 
 
173
    def disconnect(self):
 
174
        connection = self._get_connection()
 
175
        if connection is not None:
 
176
            connection.close()
 
177
 
173
178
    def _translate_ftp_error(self, err, path, extra=None,
174
179
                              unknown_exc=FtpPathError):
175
180
        """Try to translate an ftplib exception to a bzrlib exception.