Ticket #1978: ticket1978fix_against20060731svn.diff

File ticket1978fix_against20060731svn.diff, 625 bytes (added by tvachon, 16 years ago)

patch to fix this defect

  • imap4.py

    old new  
    17271727        if _w is None:
    17281728            _w = self.transport.write
    17291729        for p in part.part:
    1730             msg = msg.getSubPart(p)
     1730            if msg.isMultipart():
     1731                msg = msg.getSubPart(p)
     1732            else:
     1733                if p > 0:
     1734                    raise TypeError, "Requested subpart of non-multipart message"
     1735
    17311736        if part.header:
    17321737            hdrs = msg.getHeaders(part.header.negate, *part.header.fields)
    17331738            hdrs = _formatHeaders(hdrs)