@@ -604,6 +604,7 @@ int main(int argc, char **argv)
604
604
}
605
605
if (set_increment ) {
606
606
int num_displayable ;
607
+ int num_added ;
607
608
if (set_linkquotes )
608
609
replylist = NULL ;
609
610
/* we have to start with the msgnum - 1 so that the rest of the
@@ -613,29 +614,32 @@ int main(int argc, char **argv)
613
614
amount_old = max_msgnum + 1 ; /* counts gaps as messages */
614
615
615
616
/* start numbering at this number */
616
- amount_new = num_displayable + parsemail (set_mbox , use_stdin , set_readone , set_increment , set_dir , set_inlinehtml , amount_old );
617
- if (set_linkquotes )
618
- analyze_headers (max_msgnum + 1 );
619
-
620
- /* write the index of msgno/msgid_hash filenames */
621
- if (set_nonsequential )
622
- write_messageindex (0 , max_msgnum + 1 );
623
-
624
- writearticles (amount_old , max_msgnum + 1 );
625
-
626
- /* JK: in function of other hypermail configuration options,
627
- delete_incremental will continuous escape and add more markup
628
- to non-deleted messages that are replies to deleted messages.
629
- Thus, a setup option to disable it */
630
- if (set_delete_incremental && deletedlist )
631
- update_deletions (amount_old );
632
-
633
- if (set_show_msg_links ) {
634
- fixnextheader (set_dir , amount_old , -1 );
635
- for (i = amount_old ; i <= max_msgnum ; ++ i ) {
636
- if (set_showreplies )
637
- fixreplyheader (set_dir , i , 0 , amount_old );
638
- fixthreadheader (set_dir , i , amount_old );
617
+ num_added = parsemail (set_mbox , use_stdin , set_readone , set_increment , set_dir , set_inlinehtml , amount_old );
618
+ if (num_added > 0 ) {
619
+ amount_new = num_displayable + num_added ;
620
+ if (set_linkquotes )
621
+ analyze_headers (max_msgnum + 1 );
622
+
623
+ /* write the index of msgno/msgid_hash filenames */
624
+ if (set_nonsequential )
625
+ write_messageindex (0 , max_msgnum + 1 );
626
+
627
+ writearticles (amount_old , max_msgnum + 1 );
628
+
629
+ /* JK: in function of other hypermail configuration options,
630
+ delete_incremental will continuous escape and add more markup
631
+ to non-deleted messages that are replies to deleted messages.
632
+ Thus, a setup option to disable it */
633
+ if (set_delete_incremental && deletedlist )
634
+ update_deletions (amount_old );
635
+
636
+ if (set_show_msg_links ) {
637
+ fixnextheader (set_dir , amount_old , -1 );
638
+ for (i = amount_old ; i <= max_msgnum ; ++ i ) {
639
+ if (set_showreplies )
640
+ fixreplyheader (set_dir , i , 0 , amount_old );
641
+ fixthreadheader (set_dir , i , amount_old );
642
+ }
639
643
}
640
644
}
641
645
}
0 commit comments