/*
* Server-side module for Wiki rooms. This handles things like version control.
*
- * Copyright (c) 2009-2022 by the citadel.org team
+ * Copyright (c) 2009-2023 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.
history_msg->cm_magic = CTDLMESSAGE_MAGIC;
history_msg->cm_anon_type = MES_NORMAL;
history_msg->cm_format_type = FMT_RFC822;
- CM_SetField(history_msg, eAuthor, HKEY("Citadel"));
+ CM_SetField(history_msg, eAuthor, "Citadel");
if (!IsEmptyStr(CC->room.QRname)){
- CM_SetField(history_msg, eRecipient, CC->room.QRname, strlen(CC->room.QRname));
+ CM_SetField(history_msg, eRecipient, CC->room.QRname);
}
- CM_SetField(history_msg, eExclusiveID, history_page, history_page_len);
- CM_SetField(history_msg, eMsgSubject, history_page, history_page_len);
- CM_SetField(history_msg, eSuppressIdx, HKEY("1")); /* suppress full text indexing */
+ CM_SetField(history_msg, eExclusiveID, history_page);
+ CM_SetField(history_msg, eMsgSubject, history_page);
+ CM_SetField(history_msg, eSuppressIdx, "1"); /* suppress full text indexing */
snprintf(boundary, sizeof boundary, "Citadel--Multipart--%04x--%08lx", getpid(), time(NULL));
buf = (char*) malloc(1024);
len = snprintf(buf, 1024,
msgnum = (-1L);
}
else if (!strcasecmp(operation, "fetch")) {
- CM_SetField(msg, eAuthor, HKEY("Citadel"));
+ CM_SetField(msg, eAuthor, "Citadel");
CtdlCreateRoom(wwm, 5, "", 0, 1, 1, VIEW_BBS); /* Not an error if already exists */
msgnum = CtdlSubmitMsg(msg, NULL, wwm); /* Store the revision here */
else if (!strcasecmp(operation, "revert")) {
CM_SetFieldLONG(msg, eTimestamp, time(NULL));
if (!IsEmptyStr(CC->user.fullname)) {
- CM_SetField(msg, eAuthor, CC->user.fullname, strlen(CC->user.fullname));
+ CM_SetField(msg, eAuthor, CC->user.fullname);
}
if (!IsEmptyStr(CC->cs_inet_email)) {
- CM_SetField(msg, erFc822Addr, CC->cs_inet_email, strlen(CC->cs_inet_email));
+ CM_SetField(msg, erFc822Addr, CC->cs_inet_email);
}
if (!IsEmptyStr(CC->room.QRname)) {
- CM_SetField(msg, eOriginalRoom, CC->room.QRname, strlen(CC->room.QRname));
+ CM_SetField(msg, eOriginalRoom, CC->room.QRname);
}
if (!IsEmptyStr(pagename)) {
- CM_SetField(msg, eExclusiveID, pagename, strlen(pagename));
+ CM_SetField(msg, eExclusiveID, pagename);
}
msgnum = CtdlSubmitMsg(msg, NULL, ""); /* Replace the current revision */
}