Closed
Bug 279745
Opened 21 years ago
Closed 17 years ago
(erroneous?) quote as block comment triggers plain text conversion warning
Categories
(MailNews Core :: MIME, defect)
MailNews Core
MIME
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: neil, Assigned: neil)
Details
Attachments
(4 files)
750 bytes,
patch
|
BenB
:
review-
standard8
:
review+
Bienvenu
:
superreview+
|
Details | Diff | Splinter Review |
34.86 KB,
image/png
|
Details | |
29.80 KB,
image/png
|
Details | |
1.09 KB,
patch
|
Bienvenu
:
review+
|
Details | Diff | Splinter Review |
Steps to reproduce problem:
1. Find a plain text message that quotes another message
2. Reply to it in HTML format
3. Set your send format to auto-detect
4. Post your reply, but without adding your own formatting
Expected result: reply posted
Actual result: HTML conversion warning.
This appears to be triggered by an HTML comment inserted by mimetpla.cpp
Assignee | ||
Comment 1•21 years ago
|
||
This works for me but then I don't understand why that code was there
originally.
Assignee: sspitzer → neil.parkwaycc.co.uk
Status: NEW → ASSIGNED
Attachment #172343 -
Flags: superreview?(bienvenu)
Attachment #172343 -
Flags: review?(ben.bucksch)
Comment 2•21 years ago
|
||
As the comment says, I had a case where Gecko didn't put out a linebreak (after
a quote when sender's text starts, I think), although it should have, and that
fixed it. Maybe the bug has been fixed by now, but I don't know the exact
probloem anymore to test it, and there are a variety of cases. Maybe I'll test
it, when I get around to test bug 130728.
Updated•17 years ago
|
QA Contact: mime
Updated•17 years ago
|
Product: Core → MailNews Core
![]() |
||
Comment 3•17 years ago
|
||
Neil, Ben, ping on this bug with a patch pending reviews.
![]() |
||
Comment 4•17 years ago
|
||
(In reply to comment #3)
> Neil, Ben, ping on this bug with a patch pending reviews.
bienvenu too...
fwiw, I just tested this patch and (yay!) it has not bitrotted over the last 4 years. :)
![]() |
||
Updated•17 years ago
|
Attachment #172343 -
Flags: superreview?(bienvenu) → superreview+
Assignee | ||
Updated•17 years ago
|
Attachment #172343 -
Flags: review?(bugzilla)
Comment 5•17 years ago
|
||
Comment on attachment 172343 [details] [diff] [review]
Proposed patch
I couldn't trigger the error, but we shouldn't have to be doing this anyway, and if we do, it seems like a separate bug.
Attachment #172343 -
Flags: review?(bugzilla) → review+
Assignee | ||
Comment 6•17 years ago
|
||
Pushed changeset 5210f1319bcd to comm-central.
Status: ASSIGNED → RESOLVED
Closed: 17 years ago
Resolution: --- → FIXED
Comment 7•17 years ago
|
||
And now blank lines between quoted and normal text are missing. *g*
Left is without the patch and right with the patch.
Assignee | ||
Comment 8•17 years ago
|
||
If you use DOM Inspector to delete the comment nodes from the DOM generated by the previous version, do the blank lines disappear there too?
Comment 9•17 years ago
|
||
Sorry, i am not familiar with the DOM Inspector.
Assignee | ||
Comment 10•17 years ago
|
||
In that case, would you mind attaching the message, so that I have a known test case, and also let me know whether you are using any non-default preferences e.g. for disabling format=flowed.
Comment 11•17 years ago
|
||
Hm, you do not see this missing blank lines? The first screenshot was from a posting in de.comm.software.mozilla.nightly-builds, the second is from mozilla.dev.apps.seamonkey.
<M66dnYPEQsLCIjLUnZ2dnUVZ_vSdnZ2d@mozilla.org>
I assume that you have access to news.mozilla.org and can see this posting there. ;)
My preferences, which may affect this bug:
user_pref("mail.quoted_graphical", false);
user_pref("mailnews.display.disable_format_flowed_support", true);
user_pref("mail.quoteasblock", false);
Comment 12•17 years ago
|
||
Thanks Hartmut.
That is *precisely* why the <!----> was there. The source code comment even says that, and I said it in comment 2.
Please back out the patch until there's a better fix.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Updated•17 years ago
|
Severity: trivial → major
Comment 13•17 years ago
|
||
(In reply to comment #8)
> If you use DOM Inspector to delete the comment nodes from the DOM generated by
> the previous version, do the blank lines disappear there too?
No.
But without the comment node, the first #text inside the <pre> gets ripped of the leading empty line.
Assignee | ||
Comment 14•17 years ago
|
||
So, philor pointed out the spec which shows that HTML eats newlines before and after tags. Most of the time this isn't a problem, because newlines usually get ignored anyway, but obviously in this one case we need to deliberately put a newline in to stop the HTML parser from eating into our data.
Attachment #366144 -
Flags: review?(philringnalda)
Assignee | ||
Updated•17 years ago
|
Attachment #366144 -
Flags: review?(philringnalda) → review?(bienvenu)
Comment 15•17 years ago
|
||
Ah, thanks!
You're sure they should be there in all these cases?
Please test with pref "mail.quoted_graphical" = true (default) and false, and
with multiple quote levels.
The other prefs mentioned should not have an influence.
Test with a normal plaintext mail, *not* format-flowed as Thunderbird emits.
(Testing f=f is useless in this bug, as f=f does not go through this class.)
Assignee | ||
Comment 16•17 years ago
|
||
(In reply to comment #15)
> You're sure they should be there in all these cases?
The point is that adding the \n in all cases leads to reproducible behaviour (i.e. it ceases to matter what the following data is.)
> Please test with pref "mail.quoted_graphical" = true (default) and false, and
> with multiple quote levels.
Done.
> The other prefs mentioned should not have an influence.
> Test with a normal plaintext mail, *not* format-flowed as Thunderbird emits.
> (Testing f=f is useless in this bug, as f=f does not go through this class.)
Actually that is why the suggestion was to use
user_pref("mailnews.display.disable_format_flowed_support", true);
as then this code gets used even for f=f mail.
user_pref("mailnews.quoteasblock") seems to affect replying in HTML format.
user_pref("mailnews.quoted_graphical") only affects the display of the >s.
![]() |
||
Updated•17 years ago
|
Attachment #366144 -
Flags: review?(bienvenu) → review+
Assignee | ||
Comment 17•17 years ago
|
||
Pushed changeset dc17a79d4b83 to comm-central for the regression fix.
Status: REOPENED → RESOLVED
Closed: 17 years ago → 17 years ago
Resolution: --- → FIXED
Updated•16 years ago
|
Attachment #172343 -
Flags: review?(ben.bucksch) → review-
You need to log in
before you can comment on or make changes to this bug.
Description
•