diff options
author | Eduardo Chappa <chappa@washington.edu> | 2014-12-07 19:42:37 -0700 |
---|---|---|
committer | Eduardo Chappa <chappa@washington.edu> | 2014-12-07 19:42:37 -0700 |
commit | 20d433c77e32dc05c2accf8ab943c2a7d9738239 (patch) | |
tree | 4cf7be2b55ec529067a2867eb29ebcfe6c5758aa /alpine/mailcmd.c | |
parent | 121a42f3d82c1b98c384857960d14b2057a95c41 (diff) | |
download | alpine-20d433c77e32dc05c2accf8ab943c2a7d9738239.tar.xz |
* new version 2.19.9993
* Aggregate operations allows bouncing a list of messages using a role.
Suggested by Ulf-Dietrich Braumann.
* Compilation error of module pith/reply.c if SMIME is not defined (as in
Windows Alpine). There was a misplaced parenthesis.
* Update to S/MIME to explain how to use a PKCS12 certificate in
Alpine.
* Fix error in compare_certs function, that would modify the name of
the certificates after sorting them, and return when no certificates
are given.
* When replying to several messages, subject will be decoded first,
and then stripped from re/fwd before they are compared to determine
the subject of the replied message.
* Add $(LIBINTL) to the flags to link rpdump, rpload, alpined and
alpineldap because MAC OSX 10.8 x86_64 needs it.
* When the download of an attachment is interrumpted, Alpine stills
caches what was downloaded, making the download incomplete for
subsequent calls of Alpine attempting to open the attachment. In the
future, Alpine will not cache any downloaded part of the attachment
when it is interrupted.
Diffstat (limited to 'alpine/mailcmd.c')
-rw-r--r-- | alpine/mailcmd.c | 60 |
1 files changed, 55 insertions, 5 deletions
diff --git a/alpine/mailcmd.c b/alpine/mailcmd.c index bde099c6..163fdff6 100644 --- a/alpine/mailcmd.c +++ b/alpine/mailcmd.c @@ -1502,7 +1502,7 @@ get_out: /*--------- Default, unknown command ----------*/ default: - panic("Unexpected command case"); + alpine_panic("Unexpected command case"); break; } @@ -2366,12 +2366,62 @@ int cmd_bounce(struct pine *state, MSGNO_S *msgmap, int aopt) { int rv = 0; + ACTION_S *role = NULL; if(any_messages(msgmap, NULL, "to Bounce")){ if(MCMD_ISAGG(aopt) && !pseudo_selected(state->mail_stream, msgmap)) return rv; - rv = bounce(state, NULL); + if(MCMD_ISAGG(aopt)){ /* check for possible role */ + PAT_STATE pstate; + int action; + + if(nonempty_patterns(ROLE_DO_ROLES, &pstate) && first_pattern(&pstate)){ + static ESCKEY_S yesno_opts[] = { + {'y', 'y', "Y", N_("Yes")}, + {'n', 'n', "N", N_("No")}, + {-1, 0, NULL, NULL} + }; + + action = radio_buttons(_("Bounce messages using a role? "), + -FOOTER_ROWS(state), yesno_opts, + 'y', 'x', h_role_compose, RB_NORM); + if(action == 'y'){ + void (*prev_screen)(struct pine *) = NULL, (*redraw)(void) = NULL; + + redraw = state->redrawer; + state->redrawer = NULL; + prev_screen = state->prev_screen; + role = NULL; + state->next_screen = SCREEN_FUN_NULL; + + if(role_select_screen(state, &role, MC_BOUNCE) < 0) + cmd_cancelled(_("Bounce")); + else{ + if(role) + role = combine_inherited_role(role); + else{ + role = (ACTION_S *) fs_get(sizeof(*role)); + memset((void *) role, 0, sizeof(*role)); + role->nick = cpystr("Default Role"); + } + } + + if(redraw) + (*redraw)(); + + state->next_screen = prev_screen; + state->redrawer = redraw; + state->mangled_screen = 1; + } + } + } + + rv = bounce(state, role); + + if(role) + free_action(&role); + if(MCMD_ISAGG(aopt)) restore_selected(msgmap); @@ -2696,7 +2746,7 @@ save_prompt(struct pine *state, CONTEXT_S **cntxt, char *nfldr, size_t len_nfldr ESCKEY_S ekey[10]; if(!cntxt) - panic("no context ptr in save_prompt"); + alpine_panic("no context ptr in save_prompt"); init_hist(&history, HISTSIZE); @@ -3079,7 +3129,7 @@ save_prompt(struct pine *state, CONTEXT_S **cntxt, char *nfldr, size_t len_nfldr break; default : - panic("Unhandled case"); + alpine_panic("Unhandled case"); break; } @@ -5772,7 +5822,7 @@ broach_folder(int qline, int allow_list, int *notrealinbox, CONTEXT_S **context) break; default : - panic("Unhandled case"); + alpine_panic("Unhandled case"); break; } |