Closed
Bug 260482
Opened 20 years ago
Closed 20 years ago
custom mail headers (e.g. In-Reply-To) cannot be passed from command line
Categories
(Thunderbird :: General, defect)
Thunderbird
General
Tracking
(Not tracked)
VERIFIED
FIXED
Thunderbird1.1
People
(Reporter: asac, Assigned: mscott)
References
()
Details
Attachments
(1 file, 2 obsolete files)
3.22 KB,
patch
|
Bienvenu
:
review+
mscott
:
superreview+
mscott
:
approval-aviary1.1a2+
|
Details | Diff | Splinter Review |
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6) Gecko/20040614 Firefox/0.8
Build Identifier: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.6) Gecko/20040614 Firefox/0.8
though, the -compose (and its remote counterpart) allows adding the Subject of a
new mail composed it does not consume other custom mail headers passed in.
A good example is the In-Reply-To header as used in the Reply-To links in the
debian mailing list, e.g.:
http://lists.debian.org/debian-devel/2004/09/msg00050.html
If you click any of the reply-to links the In-Reply-To parameter will be
ignored, thus breaking threads.
Reproducible: Always
Steps to Reproduce:
1. Click:
mailto:debian-devel@lists.debian.org?In-Reply-To=<20040901190002.GA28033@quux.local>&Subject=Re:%20Re:
Firefox and Sarge
3. subject will be included, but In-Reply-To won't
Reporter | ||
Comment 1•20 years ago
|
||
the link to click broke when pasting in. Please go to
http://lists.debian.org/debian-devel/2004/09/msg00050.html and press the
reply-to link to reproduce this!
Comment 2•20 years ago
|
||
*** Bug 263905 has been marked as a duplicate of this bug. ***
Comment 3•20 years ago
|
||
RFC 2368 specifically cites In-Reply-To as a header that could be passed in via
mailto:.
Status: UNCONFIRMED → NEW
Ever confirmed: true
OS: Linux → All
Hardware: PC → All
Attached please find a pretty minor patch that gives Thunderbird the ability to
recognize In-Reply-To and References fields in a mailto URI and use them when
composing an email. Tested with Thunderbird 0.9 on Debian GNU/Linux and
confirmed to work.
There is a slight issue with this fix: if a URI supplies both In-Reply-To and
References fields, the last of these fields to be specified will override
values specified in the others. This is a limitation in the way that
Thunderbird source code handles In-Reply-To (basically it just treats it as the
most recent Reference), and can't be fixed without a lot more work.
Maybe this also applies against the Mozilla suite? I haven't checked. Anyone
willing to apply this in CVS for me?
Comment 5•20 years ago
|
||
Comment on attachment 166328 [details] [diff] [review]
Patch to implement In-Reply-To in mailto URI
Other than some minor indentation nits, that patch looks OK to me, but what do
I know? You need a reviewer.
Attachment #166328 -
Flags: review?(bienvenu)
Comment 6•20 years ago
|
||
Comment on attachment 166328 [details] [diff] [review]
Patch to implement In-Reply-To in mailto URI
looks fine, but you need to get rid of the tabs and fix the indentation...
Attachment #166328 -
Flags: superreview?(mscott)
Attachment #166328 -
Flags: review?(bienvenu)
Attachment #166328 -
Flags: review+
Here is an improved patch that fixes the issue I mentioned earlier. If only
one of References or In-Reply-To is specified in the mailto URI, its value is
copied into m_referencePart. If both are specified, the value of References is
copied into m_referencePart, and if the last field in References is different
from the In-Reply-To value, the In-Reply-To value is appended to
m_referencePart. Maybe this is too pedantic (who will ever specify References
in a mailto URI?), but better safe than sorry.
I also got rid of tabs in the added code, and fixed indentation and brace style
to match the surrounding code as best I could (it's pretty inconsistent in
nsSmtpUrl.cpp).
This revised patch was also tested with Thunderbird 0.9 on Debian.
Attachment #166328 -
Attachment is obsolete: true
Comment 8•20 years ago
|
||
(kmccarty) -- you need to request reviews on patches if you expect things to
move forward. I did that for you once, but I'm done holding your hand.
Comment 9•20 years ago
|
||
*** Bug 129934 has been marked as a duplicate of this bug. ***
Attachment #166350 -
Flags: review?(bienvenu)
Comment 10•20 years ago
|
||
Mike - sorry, this is the first patch I've submitted for Mozilla so I'm still
getting the hang of this. Just added a review request, and finally remembered
to have changes to this bug CC'ed to my email.
Comment 11•20 years ago
|
||
Comment on attachment 166350 [details] [diff] [review]
Improved patch for In-Reply-To in mailto URI
it looks like there are tabs in the first part of your patch - we don't checkin
tabs - we use spaces.
+ if (lastRef)
+ lastReference = lastRef;
+ else
+ lastReference = m_referencePart;
this can just be:
lastReference = (lastRef) ? lastRef : m_referencePart;
r=bienvenu with those fixes (tabs and ? operator)
Attachment #166350 -
Flags: review?(bienvenu) → review+
Comment 12•20 years ago
|
||
(In reply to comment #11)
> (From update of attachment 166350 [details] [diff] [review])
> it looks like there are tabs in the first part of your patch - we don't checkin
> tabs - we use spaces.
There are no tabs in the new code; only in the old code which the diff is
against. Should I take them out of the diff even though that will make the
patch not apply cleanly without the -l option?
> + if (lastRef)
> + lastReference = lastRef;
> + else
> + lastReference = m_referencePart;
>
> this can just be:
>
> lastReference = (lastRef) ? lastRef : m_referencePart;
I think I tried this and my compiler (g++ 3.3) errored out with the complaint
that operator?: isn't defined for nsCAutoString. Wait a bit and I will try it
again to make sure.
Comment 13•20 years ago
|
||
Comment on attachment 166350 [details] [diff] [review]
Improved patch for In-Reply-To in mailto URI
there must be tabs here:
+ case 'I':
+ if (!nsCRT::strcasecmp (token,
"in-reply-to"))
+ inReplyToPart = value;
+ break;
re the ? operator, sorry about that - I think you could try
m_referencePart.get()
Comment 14•20 years ago
|
||
(In reply to comment #13)
> (From update of attachment 166350 [details] [diff] [review])
> there must be tabs here:
>
> + case 'I':
> + if (!nsCRT::strcasecmp (token,
> "in-reply-to"))
> + inReplyToPart = value;
> + break;
Just spaces, believe it or not. I was trying to keep the same indentation as
the surrounding code, which uses tabs. Should I change the spacing to be
consistent if tabs are set to 2 columns instead of 8?
> re the ? operator, sorry about that - I think you could try
> m_referencePart.get()
OK, that ought to work.
Comment 15•20 years ago
|
||
it's OK - I'll clean up the indentation when I check it in...assuming you don't
have cvs access.
Comment 16•20 years ago
|
||
> it's OK - I'll clean up the indentation when I check it in...assuming you
don't
> have cvs access.
David: thank you. No, I don't have CVS access, although I would be happy to
clean up tabs if I did.
Here is the patch with ?: operator used.
Attachment #166350 -
Attachment is obsolete: true
Attachment #167366 -
Flags: review?(bienvenu)
Updated•20 years ago
|
Attachment #167366 -
Flags: review?(bienvenu) → review+
Updated•20 years ago
|
Attachment #167366 -
Flags: superreview?(mscott)
Reporter | ||
Comment 17•20 years ago
|
||
any news or reasons why not to include this patch?
Assignee | ||
Updated•20 years ago
|
Attachment #167366 -
Flags: superreview?(mscott) → superreview+
Assignee | ||
Comment 18•20 years ago
|
||
putting on the 1.1 radar so we don't forget to check this in
Target Milestone: --- → Thunderbird1.1
Updated•20 years ago
|
Attachment #167366 -
Flags: approval-aviary1.1a?
Comment 19•20 years ago
|
||
Comment on attachment 167366 [details] [diff] [review]
In-Reply-To in mailto patch, take 3.
a=sspitzer for aviary 1.1a
Attachment #167366 -
Flags: approval-aviary1.1a? → approval-aviary1.1a+
Assignee | ||
Comment 20•20 years ago
|
||
Comment on attachment 167366 [details] [diff] [review]
In-Reply-To in mailto patch, take 3.
moving the + to 1.1a2 not 1.1a1
Attachment #167366 -
Flags: approval-aviary1.1a1+ → approval-aviary1.1a2+
Assignee | ||
Updated•20 years ago
|
Status: NEW → RESOLVED
Closed: 20 years ago
Resolution: --- → FIXED
Updated•20 years ago
|
Attachment #166328 -
Flags: superreview?(mscott)
Comment 21•20 years ago
|
||
*** Bug 88441 has been marked as a duplicate of this bug. ***
Comment 23•13 years ago
|
||
I'm now having this error again with Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.18) Gecko/20110617 Thunderbird/3.1.11.
Comment 24•13 years ago
|
||
In the original example only the To: field is recognized.
In this example http://www.2ality.com/2011/05/replying-to-digests.html , subject works as well, but In-Reply-To is put in the body.
Comment 25•13 years ago
|
||
I've verified that it's not a problem in the browser or mailman, because it works with Thunderbird on Windows, but fields are not passed on Ubuntu. CUrrently I'm using Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.23) Gecko/20110922 Thunderbird/3.1.15.
By the way, as a workaround I'm using custom headers added by hand, but it's not very handy. http://kb.mozillazine.org/Custom_headers
Comment 26•13 years ago
|
||
Some more debugging (sorry, Italian terminal).
$ thunderbird mailto:debian-devel@lists.debian.org?In-Reply-To=<20040901190002.GA28033@quux.local>&Subject=Re:%20Re:
bash: 20040901190002.GA28033@quux.local: File o directory non esistente
(file or directory not found)
$ thunderbird "mailto:debian-devel@lists.debian.org?In-Reply-To=<20040901190002.GA28033@quux.local>&Subject=Re:%20Re:"
WORKS
$ thunderbird mailto:joe@example.com,mailing-list@example.com?body=In-Reply-To%3A%20%3C9755A732585E%40example.com%3E&In-Reply-To=%3C9755A732585E%40example.com%3E&subject=Re%3A%20I%20have%20a%20question
[1] 14166
Comando "amp" non trovato, ma ce ne sono 16 simili
amp: comando non trovato
[1]+ Eseguito thunderbird mailto:joe@example.com,mailing-list@example.com?body=In-Reply-To%3A%20%3C9755A732585E%40example.com%3E
[1] 14179
Comando "amp" non trovato, ma ce ne sono 16 simili
amp: comando non trovato
(Command "amp" not found.)
$ thunderbird "mailto:joe@example.com,mailing-list@example.com?body=In-Reply-To%3A%20%3C9755A732585E%40example.com%3E&In-Reply-To=%3C9755A732585E%40example.com%3E&subject=Re%3A%20I%20have%20a%20question"
Passes only To: and body.
You need to log in
before you can comment on or make changes to this bug.
Description
•