summaryrefslogtreecommitdiffstats
path: root/compose.c
diff options
context:
space:
mode:
authorThomas Roessler <roessler@does-not-exist.org>1998-08-31 13:41:19 +0000
committerThomas Roessler <roessler@does-not-exist.org>1998-08-31 13:41:19 +0000
commitba2162090499da23179cb420dc2bf570b1308876 (patch)
tree2f5c46e62521d82344dfe2ab1dac69b3c509ec4f /compose.c
parent43301fe8629138f9c0770c4896365a2ecf15aa4b (diff)
Updating to patch-0.94.4.vikas.attach_message.3.
Diffstat (limited to 'compose.c')
-rw-r--r--compose.c14
1 files changed, 12 insertions, 2 deletions
diff --git a/compose.c b/compose.c
index f2049f75..2ab36b74 100644
--- a/compose.c
+++ b/compose.c
@@ -651,6 +651,16 @@ int mutt_send_menu (HEADER *msg, /* structure for new message */
this = Context; /* remember current folder */
Context = ctx;
close = mutt_index_menu (1);
+ if (!Context)
+ {
+ /* go back to the folder we started from */
+ Context = this;
+ /* Restore old $sort and $sort_aux */
+ Sort = oldSort;
+ SortAux = oldSortAux;
+ menu->redraw |= REDRAW_INDEX | REDRAW_STATUS;
+ break;
+ }
}
{
int numtag = 0;
@@ -681,9 +691,9 @@ int mutt_send_menu (HEADER *msg, /* structure for new message */
else
{
HEADER *h;
- for (i = 0; i < Context->vcount; i++)
+ for (i = 0; i < Context->msgcount; i++)
{
- h = Context->hdrs[Context->v2r[i]];
+ h = Context->hdrs[i];
if (h->tagged)
{
idx[idxlen] = (ATTACHPTR *) safe_calloc (1, sizeof (ATTACHPTR));