changeset: 6319:5648f4b2ed44
user: Michael Elkins <[email protected]>
date: Wed Oct 16 16:04:29 2013 +0000
link: http://dev.mutt.org/hg/mutt/rev/5648f4b2ed44
Rework logic to avoid advancing list pointer inside the for loop.
closes #3531
diffs (16 lines):
diff -r 20954d6af1b1 -r 5648f4b2ed44 rfc822.c
--- a/rfc822.c Tue Oct 15 15:41:29 2013 +0000
+++ b/rfc822.c Wed Oct 16 16:04:29 2013 +0000
@@ -812,10 +812,9 @@
{
if (prune && addr->group && (!addr->next || !addr->next->mailbox))
{
- addr = addr->next;
- continue;
+ /* ignore this element of the list */
}
- if (last)
+ else if (last)
{
last->next = rfc822_cpy_adr_real (addr);
last = last->next;