X-Git-Url: https://code.citadel.org/?a=blobdiff_plain;f=citadel%2Fmodules%2Fnetwork%2Fserv_network.c;h=b71d95a5f8d81f40454c1f0dd4ceb1556f00d9e8;hb=7d48a403f792b4b0fb82e64d9f57a90fbc1b1933;hp=86102e0a369ad15881f8f75ddb4c9b207523d324;hpb=97d307f731cbebf405109d3f2add167cdcaaee95;p=citadel.git diff --git a/citadel/modules/network/serv_network.c b/citadel/modules/network/serv_network.c index 86102e0a3..b71d95a5f 100644 --- a/citadel/modules/network/serv_network.c +++ b/citadel/modules/network/serv_network.c @@ -478,6 +478,15 @@ void network_deliver_digest(SpoolControl *sc) { msg->cm_fields['F'] = strdup(buf); msg->cm_fields['R'] = strdup(buf); + /* Set the 'List-ID' header */ + msg->cm_fields['L'] = malloc(1024); + snprintf(msg->cm_fields['L'], 1024, + "%s <%ld.list-id.%s>", + CC->room.QRname, + CC->room.QRnumber, + config.c_fqdn + ); + /* * Go fetch the contents of the digest */ @@ -610,6 +619,18 @@ void network_spool_msg(long msgnum, void *userdata) { msg = CtdlFetchMessage(msgnum, 1); if (msg != NULL) { + /* Set the 'List-ID' header */ + if (msg->cm_fields['L'] != NULL) { + free(msg->cm_fields['L']); + } + msg->cm_fields['L'] = malloc(1024); + snprintf(msg->cm_fields['L'], 1024, + "%s <%ld.list-id.%s>", + CC->room.QRname, + CC->room.QRnumber, + config.c_fqdn + ); + /* Prepend "[List name]" to the subject */ if (msg->cm_fields['U'] == NULL) { msg->cm_fields['U'] = strdup("(no subject)");