~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/smart/medium.py

(jameinel) Treat socket.error(EPIPE) as a ConnectionReset (bug #1047325) so
 that clients will properly reconnect. (John A Meinel)

Show diffs side-by-side

added added

removed removed

Lines of Context:
910
910
        except IOError, e:
911
911
            if e.errno in (errno.EINVAL, errno.EPIPE):
912
912
                raise errors.ConnectionReset(
913
 
                    "Error trying to write to subprocess:\n%s" % (e,))
 
913
                    "Error trying to write to subprocess", e)
914
914
            raise
915
915
        self._report_activity(len(bytes), 'write')
916
916
 
1043
1043
 
1044
1044
class SmartClientSocketMedium(SmartClientStreamMedium):
1045
1045
    """A client medium using a socket.
1046
 
    
 
1046
 
1047
1047
    This class isn't usable directly.  Use one of its subclasses instead.
1048
1048
    """
1049
1049