As you can see from the fact that some variable names contain 'line' word in nsImportTextAddress::DeteminDelim, The function aims to count tab and comma line by line but actually it fails.
First, NULL-terminated position is always kTextAddressBufferSz - 1, it should be read bytes from stream, in this case it's 'left' variable. (The variable name is not good at all, by the way)
Second, nsIInputStream is used instead of nsILineInputStream.
Created attachment 575078 [details] [diff] [review]
Created attachment 575079 [details] [diff] [review]
(In reply to Hiroyuki Ikezoe (:hiro) from comment #2)
> Created attachment 575079 [details] [diff] [review] [diff] [details] [review]
> A test
This test depend on importHelper.js in bug 700920.
Comment on attachment 575078 [details] [diff] [review]
The patch didn't apply cleanly, but when I fixed it, it passed the tests...
Created attachment 636594 [details] [diff] [review]
Created attachment 636595 [details] [diff] [review]
So should these be checkin-needed ?
(In reply to Ludovic Hirlimann [:Usul] from comment #7)
> So should these be checkin-needed ?
Yes. Thanks for the notice. I do sometimes forget the flag.