* This file contains functions which handle the mapping of Internet addresses
* to users on the Citadel system.
*
- * Copyright (c) 1987-2020 by the citadel.org team
+ * Copyright (c) 1987-2021 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.
*/
int CtdlIsMe(char *addr, int addr_buf_len)
{
- recptypes *recp;
+ struct recptypes *recp;
int i;
recp = validate_recipients(addr, NULL, 0);
*
* Caller needs to free the result using free_recipients()
*/
-recptypes *validate_recipients(const char *supplied_recipients, const char *RemoteIdentifier, int Flags) {
+struct recptypes *validate_recipients(const char *supplied_recipients, const char *RemoteIdentifier, int Flags) {
struct CitContext *CCC = CC;
- recptypes *ret;
+ struct recptypes *ret;
char *recipients = NULL;
char *org_recp;
char this_recp[256];
int in_quotes = 0;
/* Initialize */
- ret = (recptypes *) malloc(sizeof(recptypes));
+ ret = (struct recptypes *) malloc(sizeof(struct recptypes));
if (ret == NULL) return(NULL);
/* Set all strings to null and numeric values to zero */
- memset(ret, 0, sizeof(recptypes));
+ memset(ret, 0, sizeof(struct recptypes));
if (supplied_recipients == NULL) {
recipients = strdup("");
/*
* Destructor for recptypes
*/
-void free_recipients(recptypes *valid) {
+void free_recipients(struct recptypes *valid) {
if (valid == NULL) {
return;
snprintf(synthetic_email_addr, sizeof synthetic_email_addr, "ctdl%08x@%s", i, CtdlGetConfigStr("c_fqdn"));
}
u = CtdlDirectoryLookup(NULL, synthetic_email_addr, 0);
- syslog(LOG_DEBUG, "\033[33mAddress <%s> lookup <%d>\033[0m", synthetic_email_addr, u);
+ syslog(LOG_DEBUG, "user_ops: address <%s> lookup returned <%d>", synthetic_email_addr, u);
}
CtdlSetEmailAddressesForUser(user->fullname, synthetic_email_addr);