diff options
| author | Dmitry Vyukov <dvyukov@google.com> | 2017-11-17 18:54:19 +0100 |
|---|---|---|
| committer | Dmitry Vyukov <dvyukov@google.com> | 2017-11-17 18:54:19 +0100 |
| commit | 00f6ff581c6a4296baf3271e9114cc3a18da93e6 (patch) | |
| tree | 0cf42e925471d4a60b2bfdbcbb31a260f849206d /pkg/email/patch.go | |
| parent | 2950adb95c95c76906018f1de813a3270eb4a94f (diff) | |
pkg/email: truncate garbage after patches
Diffstat (limited to 'pkg/email/patch.go')
| -rw-r--r-- | pkg/email/patch.go | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/pkg/email/patch.go b/pkg/email/patch.go index 46a31a05d..d91a6a020 100644 --- a/pkg/email/patch.go +++ b/pkg/email/patch.go @@ -23,7 +23,8 @@ func ParsePatch(text string) (title string, diff string, err error) { } } if parsingDiff { - if ln == "--" || ln == "-- " { + if ln == "" || ln == "--" || ln == "-- " || ln[0] == '>' || + ln[0] >= 'A' && ln[0] <= 'Z' { break } diff += ln + "\n" |
