X-Git-Url: https://code.citadel.org/?a=blobdiff_plain;f=citadel%2Fmodules%2Fnetwork%2Fserv_network.c;h=c61d225931a36b6327205295d10d90c1eb548f86;hb=2e810d36a66a6cc42c345bd924b4e2b7669af8cd;hp=32bf49564a1f4f7b6f370df7eacf5abe4e3cdf15;hpb=158e8958500476d1115c7b70f6c81a87bb0ade47;p=citadel.git diff --git a/citadel/modules/network/serv_network.c b/citadel/modules/network/serv_network.c index 32bf49564..c61d22593 100644 --- a/citadel/modules/network/serv_network.c +++ b/citadel/modules/network/serv_network.c @@ -96,54 +96,6 @@ typedef struct __roomlists { struct RoomProcList *rplist = NULL; - -/* - * Check the use table. This is a list of messages which have recently - * arrived on the system. It is maintained and queried to prevent the same - * message from being entered into the database multiple times if it happens - * to arrive multiple times by accident. - */ -int network_usetable(struct CtdlMessage *msg) -{ - StrBuf *msgid; - struct CitContext *CCC = CC; - time_t now; - - /* Bail out if we can't generate a message ID */ - if ((msg == NULL) || CM_IsEmpty(msg, emessageId)) - { - return(0); - } - - /* Generate the message ID */ - msgid = NewStrBufPlain(msg->cm_fields[emessageId], -1); - if (haschar(ChrPtr(msgid), '@') == 0) { - StrBufAppendBufPlain(msgid, HKEY("@"), 0); - if (!CM_IsEmpty(msg, eNodeName)) { - StrBufAppendBufPlain(msgid, msg->cm_fields[eNodeName], -1, 0); - } - else { - FreeStrBuf(&msgid); - return(0); - } - } - now = time(NULL); - if (CheckIfAlreadySeen("Networker Import", - msgid, - now, 0, - eCheckUpdate, - CCC->cs_pid, 0) != 0) - { - FreeStrBuf(&msgid); - return(1); - } - FreeStrBuf(&msgid); - - return(0); -} - - - /* * Send the *entire* contents of the current room to one specific network node, * ignoring anything we know about which messages have already undergone @@ -391,7 +343,7 @@ void network_bounce(struct CtdlMessage *msg, char *reason) msg->cm_fields[eNodeName]); CM_SetField(msg, eAuthor, HKEY(BOUNCESOURCE)); - CM_SetField(msg, eNodeName, config.c_nodename, strlen(config.c_nodename)); + CM_SetField(msg, eNodeName, CFG_KEY(c_nodename)); CM_SetField(msg, eMsgSubject, HKEY("Delivery Status Notification (Failure)")); Netmap_AddMe(msg, HKEY("unknown_user"));