Mercurial > public > mercurial-scm > hg-stable
comparison mercurial/patch.py @ 51875:454feddab720
brancing: merge stable into default
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Fri, 06 Sep 2024 02:12:19 +0200 |
parents | ca7bde5dbafb 8f629783b8ae |
children | f4733654f144 |
comparison
equal
deleted
inserted
replaced
51874:4eccb65e444f | 51875:454feddab720 |
---|---|
120 | 120 |
121 m = mail.parse(c) | 121 m = mail.parse(c) |
122 if not m.is_multipart(): | 122 if not m.is_multipart(): |
123 yield msgfp(m) | 123 yield msgfp(m) |
124 else: | 124 else: |
125 ok_types = (b'text/plain', b'text/x-diff', b'text/x-patch') | 125 ok_types = ('text/plain', 'text/x-diff', 'text/x-patch') |
126 for part in m.walk(): | 126 for part in m.walk(): |
127 ct = part.get_content_type() | 127 ct = part.get_content_type() |
128 if ct not in ok_types: | 128 if ct not in ok_types: |
129 continue | 129 continue |
130 yield msgfp(part) | 130 yield msgfp(part) |