Removed an unused parameter from CtdlSubmitMsg(). Why was it even there?
[citadel.git] / citadel / modules / network / serv_netmail.c
index 6ee61cfd57317c3aec1d45864541af63d07d2289..820c2fe9f6f8448b9b469ff55b2a914a57355b18 100644 (file)
@@ -1,7 +1,7 @@
 /*
  * This module handles network mail and mailing list processing.
  *
- * Copyright (c) 2000-2018 by the citadel.org team
+ * Copyright (c) 2000-2020 by the citadel.org team
  *
  * This program is open source software; you can redistribute it and/or modify
  * it under the terms of the GNU General Public License, version 3.
@@ -221,7 +221,7 @@ void network_deliver_digest(SpoolControl *sc)
        if (valid != NULL) {
                valid->bounce_to = strdup(bounce_to);
                valid->envelope_from = strdup(bounce_to);
-               CtdlSubmitMsg(msg, valid, NULL, 0);
+               CtdlSubmitMsg(msg, valid, NULL);
        }
        CM_Free(msg);
        free_recipients(valid);
@@ -269,11 +269,6 @@ void network_process_digest(SpoolControl *sc, struct CtdlMessage *omsg, long *de
                                "<%s> ",
                                msg->cm_fields[erFc822Addr]);
                }
-               else if (!CM_IsEmpty(msg, eNodeName)) {
-                       fprintf(sc->digestfp,
-                               "@%s ",
-                               msg->cm_fields[eNodeName]);
-               }
                fprintf(sc->digestfp, "\n");
                if (!CM_IsEmpty(msg, eMsgSubject)) {
                        fprintf(sc->digestfp,
@@ -370,7 +365,7 @@ void network_deliver_list(struct CtdlMessage *msg, SpoolControl *sc, const char
                valid->bounce_to = strdup(bounce_to);
                valid->envelope_from = strdup(bounce_to);
                valid->sending_room = strdup(RoomName);
-               CtdlSubmitMsg(msg, valid, NULL, 0);
+               CtdlSubmitMsg(msg, valid, NULL);
                free_recipients(valid);
        }
        /* Do not call CM_Free(msg) here; the caller will free it. */
@@ -397,12 +392,11 @@ void network_process_participate(SpoolControl *sc, struct CtdlMessage *omsg, lon
         * is rude...
         */
        ok_to_participate = 0;
-       if (!CM_IsEmpty(msg, eNodeName)) {
-               if (!strcasecmp(msg->cm_fields[eNodeName], CtdlGetConfigStr("c_nodename")))
-               {
-                       ok_to_participate = 1;
-               }
-       }
+
+       // FIXME -- After we removed CitaNet/IGnet support , we now need a new heuristic to determine
+       // whether a message originated locally.  This means the "participate" mode no longer works.
+       // We'll definitely need to refactor this when we do other federated stuff later.
+
        if (ok_to_participate)
        {
                /* Replace the Internet email address of the
@@ -415,7 +409,7 @@ void network_process_participate(SpoolControl *sc, struct CtdlMessage *omsg, lon
                valid = validate_recipients(ChrPtr(sc->Users[participate]) , NULL, 0);
 
                CM_SetField(msg, eRecipient, SKEY(sc->Users[roommailalias]));
-               CtdlSubmitMsg(msg, valid, "", 0);
+               CtdlSubmitMsg(msg, valid, "");
                free_recipients(valid);
        }
        CM_Free(msg);
@@ -432,7 +426,7 @@ void network_spool_msg(long msgnum, void *userdata)
        SpoolControl *sc;
 
        sc = (SpoolControl *)userdata;
-       msg = CtdlFetchMessage(msgnum, 1, 1);
+       msg = CtdlFetchMessage(msgnum, 1);
 
        if (msg == NULL)
        {