aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCatalin Marinas <catalin.marinas@gmail.com>2013-04-29 15:18:59 +0100
committerCatalin Marinas <catalin.marinas@gmail.com>2013-04-29 15:18:59 +0100
commitf7ce854ca49b61bf8b45c9371bb735d40772a860 (patch)
treeac10913c50f5f8016d3f508bb2cfb2e2a4b4c7b1
parentd1dd2342aed2fe274f7c9e9cbe893216d81919dc (diff)
downloadstgit-f7ce854ca49b61bf8b45c9371bb735d40772a860.tar.gz
mail: Do no filter explicitly added --cc sender address
With this patch, only the automatically generated sender address is filtered out. Explicitly added one is kept. Signed-off-by: Catalin Marinas <catalin.marinas@gmail.com>
-rw-r--r--stgit/commands/mail.py12
1 files changed, 5 insertions, 7 deletions
diff --git a/stgit/commands/mail.py b/stgit/commands/mail.py
index 76ad664..d551353 100644
--- a/stgit/commands/mail.py
+++ b/stgit/commands/mail.py
@@ -359,15 +359,13 @@ def __build_address_headers(msg, options, extra_cc = []):
bcc_addr = autobcc
# if an address is on a header, ignore it from the rest
+ from_set = __update_header(msg, 'From')
to_set = __update_header(msg, 'To', to_addr)
+ # --auto generated addresses, don't include the sender
+ __update_header(msg, 'Cc', extra_cc_addr, from_set)
cc_set = __update_header(msg, 'Cc', cc_addr, to_set)
bcc_set = __update_header(msg, 'Bcc', bcc_addr, to_set.union(cc_set))
- # --auto generated addresses, don't include the sender
- from_set = __update_header(msg, 'From')
- __update_header(msg, 'Cc', extra_cc_addr,
- to_set.union(bcc_set).union(from_set))
-
def __get_signers_list(msg):
"""Return the address list generated from signed-off-by and
acked-by lines in the message.
@@ -478,7 +476,7 @@ def __build_cover(tmpl, msg_id, options, patches):
prefix_str = confprefix + ' '
else:
prefix_str = ''
-
+
total_nr_str = str(len(patches))
patch_nr_str = '0'.zfill(len(total_nr_str))
if len(patches) > 1:
@@ -494,7 +492,7 @@ def __build_cover(tmpl, msg_id, options, patches):
# for backward template compatibility
'date': '',
'version': version_str,
- 'prefix': prefix_str,
+ 'prefix': prefix_str,
'patchnr': patch_nr_str,
'totalnr': total_nr_str,
'number': number_str,