Fix -bi. Bug 2590
[exim.git] / src / src / smtp_in.c
index b9cf540a95e648d6ce6729e6be0f4db7d825f19c..09586c335242c3a8f639a69fd4d8be0f40a4996a 100644 (file)
@@ -1824,9 +1824,12 @@ s_connhad_log(gstring * g)
 const uschar * sep = smtp_connection_had[SMTP_HBUFF_SIZE-1] != SCH_NONE
   ? US" C=..." : US" C=";
 
-for (int i = smtp_ch_index; i < SMTP_HBUFF_SIZE; i++, sep = US",")
+for (int i = smtp_ch_index; i < SMTP_HBUFF_SIZE; i++)
   if (smtp_connection_had[i] != SCH_NONE)
+    {
     g = string_append(g, 2, sep, smtp_names[smtp_connection_had[i]]);
+    sep = US",";
+    }
 for (int i = 0; i < smtp_ch_index; i++, sep = US",")
   g = string_append(g, 2, sep, smtp_names[smtp_connection_had[i]]);
 return g;