msg_repl->highest = atol(msg->cm_fields['T']);
template = (struct CtdlMessage *) malloc(sizeof(struct CtdlMessage));
msg_repl->highest = atol(msg->cm_fields['T']);
template = (struct CtdlMessage *) malloc(sizeof(struct CtdlMessage));
CtdlForEachMessage(MSGS_ALL, 0L, NULL, template, check_repl, NULL);
CtdlForEachMessage(MSGS_ALL, 0L, NULL, template, check_repl, NULL);
lprintf(CTDL_DEBUG, "Performing before-save hooks\n");
if (PerformMessageHooks(msg, EVT_BEFORESAVE) > 0) return(-1);
lprintf(CTDL_DEBUG, "Performing before-save hooks\n");
if (PerformMessageHooks(msg, EVT_BEFORESAVE) > 0) return(-1);
lprintf(CTDL_DEBUG, "Performing replication checks\n");
if (ReplicationChecks(msg) > 0) return(-1);
lprintf(CTDL_DEBUG, "Performing replication checks\n");
if (ReplicationChecks(msg) > 0) return(-1);