Closed Bug 101480 Opened 23 years ago Closed 23 years ago

when replying to an IMAP message, fetch by part (so we only get the body, not the attachments)

Categories

(MailNews Core :: Composition, defect, P2)

defect

Tracking

(Not tracked)

VERIFIED FIXED
mozilla0.9.6

People

(Reporter: sspitzer, Assigned: cavin)

References

Details

(Keywords: perf)

Attachments

(2 files)

when replying to an IMAP message, fetch by part (so we only get the body, not the attachments) looking at an IMAP protocol log from 4.x, we used to just get the body on reply. I've got a patch that accomplishes the goal, but it's a hack. mscott / bienvenu, can you review?
OS: Windows 2000 → All
Hardware: PC → All
from nsMsgQuote.cpp: if (!bAutoQuote) modifiedUrlSpec += "?header=only"; else if (quoteHeaders) modifiedUrlSpec += "?header=quote"; else modifiedUrlSpec += "?header=quotebody"; if this is the right approach, I might need to extend my change to nsImapUrl.cpp
honestly, I'm not sure if this is the right fix or not. It could be. I'll go look at 4.x and see what it did. Scott and I have made a few changes to this logic in the past few months to fix a few bugs and we might have inadvertently broken something. Or not...
bienvenu, thanks for looking into how 4.x did this. adding perf keyword, since doing something like this would improve reply performance when replying to an imap message with an attachment. instead of adding that call to PL_strstr() [which will be executed more often than necessary], my original approach was to explicitly call SetFetchPartsOnDemand() in nsMsgQuote in the case where we wanted the body. But that made compose depend on imap. But I could add something protocol agnostic to the nsIMsgMailNewsUrl interface, have the base implementation do nothing, and have the nsImapUrl implementation call SetFetchPartsOnDemand(). comments?
Keywords: perf
*** Bug 99446 has been marked as a duplicate of this bug. ***
Blocks: 22486
over to cavin to do the investigation and finish this off. let me know if you have questions, cavin. if we can figure this out, it would be a big perf win for replying to messages with attachments.
Assignee: sspitzer → cavin
Seth's fix is almost perfect and I just added one more case ("?header=only") to the condition test. "?header=only" is set when "Automatically quote original message when replying" is turned off (Edit|Preferences|Mail & Newsgroups|Message Compose). A patch is coming.
wow, we were fetching the whole message (and attachments!) on reply when we weren't even quoting? looks good to me, but we need david / mscott to review.
Keywords: nsbeta1+
Priority: -- → P2
Target Milestone: --- → mozilla0.9.6
Scott or David, when you get a chance, could you review this?
Comment on attachment 52070 [details] [diff] [review] A revised patch to seth's. sr=mscott
Attachment #52070 - Flags: superreview+
Fix checked in.
Status: NEW → RESOLVED
Closed: 23 years ago
Resolution: --- → FIXED
*** Bug 84139 has been marked as a duplicate of this bug. ***
Tested this with changing prefs for replying(quote above, below). With messages that are displayed inline and with binary attachments. The ones we display inline like gif, jpg shows up in the reply window but not in the attachment area. We don't fetch the attachment part anymore when replying to a message with attachment. This is true in case of mail. Please see bug 110364 this seems to be not working with news. I am verifying this bug since I logged 110364 for news. Build id: 2001-11-15-06 win98, mac os x, linux.
Status: RESOLVED → VERIFIED
this has regressed, around the time that quoting broking broke when there was that big necko landing. I'm working on the regression in http://bugzilla.mozilla.org/show_bug.cgi?id=117864
Product: MailNews → Core
Product: Core → MailNews Core
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: