summaryrefslogtreecommitdiff
path: root/pith
diff options
context:
space:
mode:
authorEduardo Chappa <chappa@washington.edu>2019-01-01 10:35:18 -0700
committerEduardo Chappa <chappa@washington.edu>2019-01-01 10:35:18 -0700
commit3fb6fc0a247bbd5a035ff9291f9022bd2a998355 (patch)
treeaa221a0655308aec357bf1aa024f4588f486a1fa /pith
parent5940080c7a073d40e7f90dde4b8d0f802a22bd69 (diff)
downloadalpine-3fb6fc0a247bbd5a035ff9291f9022bd2a998355.tar.xz
* Crash when sending an email due to improper use of memory that was
released by the system.
Diffstat (limited to 'pith')
-rw-r--r--pith/send.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/pith/send.c b/pith/send.c
index 75cd2bac..e72b6d98 100644
--- a/pith/send.c
+++ b/pith/send.c
@@ -4127,9 +4127,9 @@ remove_parameter(PARAMETER **param, char *paramname)
PARAMETER om, *qm;
om.next = *param;
for(qm = &om; qm->next != pm; qm = qm->next);
- qm->next = pm->next;
- pm->next = NULL;
+ qm->next = copy_parameters(pm->next);
mail_free_body_parameter(&pm);
+ *param = om.next;
}
}