Commit 1862cbae 1862cbae7d64ceae8e28691a5d9faad192a4f566 by Sergey Poznyakoff

Use mh_create_message_id().

1 parent 12754c27
Showing 1 changed file with 1 additions and 11 deletions
......@@ -317,17 +317,7 @@ open_mailer ()
static void
create_message_id (header_t hdr)
{
char date[4+2+2+2+2+2+1];
time_t t = time (NULL);
struct tm *tm = localtime (&t);
char *host;
char *p;
strftime (date, sizeof date, "%Y%m%d%H%M%S", tm);
mu_get_host_name (&host);
asprintf (&p, "<%s.%lu@%s>", date, (unsigned long) getpid (), host);
free (host);
char *p = mh_create_message_id (0);
header_set_value (hdr, MU_HEADER_MESSAGE_ID, p, 1);
free (p);
}
......