X-Git-Url: https://code.citadel.org/?a=blobdiff_plain;f=citadel%2Fmodules%2Flistsub%2Fserv_listsub.c;h=cf854789b0fb19e084c0805cae660f6ac41b88e9;hb=8c47559cb5ae97ec0fa35660ee16fd61a9451c72;hp=0eb2300f2247c241f327a0990d556ac7b28588f0;hpb=1e656d277fe91b7c4f5d73eab4a0dd0b7a173145;p=citadel.git diff --git a/citadel/modules/listsub/serv_listsub.c b/citadel/modules/listsub/serv_listsub.c index 0eb2300f2..cf854789b 100644 --- a/citadel/modules/listsub/serv_listsub.c +++ b/citadel/modules/listsub/serv_listsub.c @@ -3,8 +3,21 @@ * * This module handles self-service subscription/unsubscription to mail lists. * - * Copyright (C) 2002-2005 by Art Cancro and others. - * This code is released under the terms of the GNU General Public License. + * Copyright (c) 2002-2009 by the citadel.org team + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 3 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ @@ -156,7 +169,7 @@ void do_subscribe(char *room, char *email, char *subtype, char *webpage) { /* Generate and send the confirmation request */ - urlesc(urlroom, qrbuf.QRname); + urlesc(urlroom, ROOMNAMELEN, qrbuf.QRname); snprintf(confirmation_request, sizeof confirmation_request, @@ -296,7 +309,7 @@ void do_unsubscribe(char *room, char *email, char *webpage) { /* Generate and send the confirmation request */ - urlesc(urlroom, qrbuf.QRname); + urlesc(urlroom, ROOMNAMELEN, qrbuf.QRname); snprintf(confirmation_request, sizeof confirmation_request, @@ -506,7 +519,7 @@ void do_confirm(char *room, char *token) { */ if (success) { cprintf("%d %d operation(s) confirmed.\n", CIT_OK, success); - lprintf(CTDL_NOTICE, + CtdlLogPrintf(CTDL_NOTICE, "Mailing list: %s %ssubscribed to %s with token %s\n", email, (!IsEmptyStr(address_to_unsubscribe)) ? "un" : "", @@ -570,8 +583,11 @@ void cmd_subs(char *cmdbuf) { */ CTDL_MODULE_INIT(listsub) { - CtdlRegisterProtoHook(cmd_subs, "SUBS", "List subscribe/unsubscribe"); - + if (!threading) + { + CtdlRegisterProtoHook(cmd_subs, "SUBS", "List subscribe/unsubscribe"); + } + /* return our Subversion id for the Log */ return "$Id$"; }