On Fri, Mar 05, 1999 at 02:21:07PM -0600, David DeSimone <[EMAIL PROTECTED]> wrote:
> Eric Smith <[EMAIL PROTECTED]> wrote:
> > I am almost 37, all grown up now and if I press `b' that means I have
> > made my decision and am prepared to suffer the consequences.
>
> you are probably also man enough to go into the source and edit out the
> offending prompt. :)
>
> Better yet, create a config variable for it, and submit a patch. :)
Try the attached patch: it creates a quad option for bounce.
--
David Ellement
--- commands.c.orig Tue Feb 9 12:53:38 1999
+++ commands.c Sat Mar 6 14:57:54 1999
@@ -202,7 +202,7 @@
snprintf (prompt, (COLS > sizeof(prompt) ? sizeof(prompt) : COLS) - 13,
(h ? _("Bounce message to %s") : _("Bounce messages to %s")), buf);
strcat(prompt, "...?");
- if (mutt_yesorno (prompt, 1) != 1)
+ if (query_quadoption (OPT_BOUNCE, prompt) == M_NO)
{
rfc822_free_address (&adr);
CLEARLINE (LINES-1);
--- init.h.orig Wed Feb 10 08:20:11 1999
+++ init.h Sat Mar 6 14:57:54 1999
@@ -85,6 +85,7 @@
{ "auto_tag", DT_BOOL, R_NONE, OPTAUTOTAG, 0 },
{ "beep", DT_BOOL, R_NONE, OPTBEEP, 1 },
{ "beep_new", DT_BOOL, R_NONE, OPTBEEPNEW, 0 },
+ { "bounce", DT_QUAD, R_NONE, OPT_BOUNCE, M_ASKYES },
{ "charset", DT_STR, R_NONE, UL &Charset, UL "iso-8859-1" },
{ "check_new", DT_BOOL, R_NONE, OPTCHECKNEW, 1 },
{ "collapse_unread", DT_BOOL, R_NONE, OPTCOLLAPSEUNREAD, 1 },
--- mutt.h.orig Sun Feb 28 00:06:08 1999
+++ mutt.h Sat Mar 6 14:57:54 1999
@@ -259,7 +259,8 @@
OPT_REPLYTO,
OPT_ABORT,
OPT_RECALL,
- OPT_SUBJECT
+ OPT_SUBJECT,
+ OPT_BOUNCE
};
/* flags to ci_send_message() */
--- recvattach.c.orig Sat Jan 9 09:51:32 1999
+++ recvattach.c Sat Mar 6 14:57:54 1999
@@ -670,12 +670,10 @@
static void query_bounce_attachment (int tag, BODY *top, HEADER *hdr)
{
char prompt[SHORT_STRING];
- char buf[HUGE_STRING];
+ char buf[HUGE_STRING] = { 0 };
ADDRESS *adr = NULL;
int rc;
- buf[0] = 0;
-
if(!tag)
strfcpy(prompt, _("Bounce message to: "), sizeof(prompt));
else
@@ -686,13 +684,19 @@
if (rc || !buf[0])
return;
- adr = rfc822_parse_adrlist (adr, buf);
+ if (!(adr = rfc822_parse_adrlist (adr, buf)))
+ {
+ mutt_error _("Error parsing address!");
+ return;
+ }
+
adr = mutt_expand_aliases (adr);
+
buf[0] = 0;
rfc822_write_address (buf, sizeof (buf), adr);
snprintf (prompt, sizeof (prompt), tag ? _("Bounce messages to %s...?")
: _("Bounce message to %s...?"), buf);
- if (mutt_yesorno (prompt, 1) != 1)
+ if (query_quadoption (OPT_BOUNCE, prompt) == M_NO)
{
rfc822_free_address (&adr);
CLEARLINE (LINES-1);
--- doc/manual.sgml.in.orig Thu Feb 11 04:41:53 1999
+++ doc/manual.sgml.in Sat Mar 6 14:57:54 1999
@@ -2586,6 +2586,13 @@
message notifying you of new mail. This is independent of the
setting of the <ref id="beep" name="beep"> variable.
+<sect2>bounce<label id="bounce">
+<p>
+Type: quadoption<newline>
+Default: ask-yes
+
+Controls whether you will be asked to confirm bouncing messages.
+
<sect2>charset<label id="charset">
<p>
Type: string<newline>