mirror of
https://github.com/moparisthebest/k-9
synced 2024-12-02 14:02:17 -05:00
Merge pull request #218 from justdave/issue4771
Fix issue 4771 - work around > getting included in URLs when linkifying text/plain emails
This commit is contained in:
commit
3b519adf40
@ -248,7 +248,11 @@ public class HtmlConverter {
|
|||||||
if (isStartOfLine) {
|
if (isStartOfLine) {
|
||||||
quotesThisLine++;
|
quotesThisLine++;
|
||||||
} else {
|
} else {
|
||||||
buff.append(">");
|
// We use a token here which can't occur in htmlified text because > is valid
|
||||||
|
// within links (where > is not), and linkifying links will include it if we
|
||||||
|
// do it here. We'll make another pass and change this back to > after
|
||||||
|
// the linkification is done.
|
||||||
|
buff.append("<gt>");
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case '\r':
|
case '\r':
|
||||||
@ -322,6 +326,9 @@ public class HtmlConverter {
|
|||||||
|
|
||||||
text = sb.toString();
|
text = sb.toString();
|
||||||
|
|
||||||
|
// Above we replaced > with <gt>, now make it >
|
||||||
|
text = text.replaceAll("<gt>", ">");
|
||||||
|
|
||||||
return text;
|
return text;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user