Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Some plain/text line cause System.IndexOutOfRangeException #161

Closed
msa48 opened this issue Aug 11, 2015 · 0 comments
Closed

Some plain/text line cause System.IndexOutOfRangeException #161

msa48 opened this issue Aug 11, 2015 · 0 comments
Labels
bug Something isn't working

Comments

@msa48
Copy link

msa48 commented Aug 11, 2015

test case
some line ends with UrlScanner pattern ftp.

this couse to exception

   в MimeKit.Text.UrlScanner.SkipSubDomain(Char[] text, Int32 endIndex, Int32& index)
   в MimeKit.Text.UrlScanner.SkipDomain(Char[] text, Int32 endIndex, Int32& index)
   в MimeKit.Text.UrlScanner.GetWebEndIndex(UrlMatch match, Char[] text, Int32 startIndex, Int32 matchIndex, Int32 endIndex)
   в MimeKit.Text.UrlScanner.Scan(Char[] text, Int32 startIndex, Int32 count, UrlMatch& match)
   в MimeKit.Text.TextToHtml.WriteText(HtmlWriter htmlWriter, String text)
   в MimeKit.Text.TextToHtml.Convert(TextReader reader, TextWriter writer)
   в MimeKit.Text.TextConverter.Convert(String text)

because in this case endIndex is equal length of string

@jstedfast jstedfast added the bug Something isn't working label Aug 11, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants