From: Art Cancro Date: Tue, 25 May 2010 04:05:05 +0000 (+0000) Subject: * added some missing license declarations X-Git-Tag: v7.86~185 X-Git-Url: https://code.citadel.org/?p=citadel.git;a=commitdiff_plain;h=a756685375373a04dcfa4b6be45a0acd7f4be23b * added some missing license declarations --- diff --git a/webcit/addressbook_popup.c b/webcit/addressbook_popup.c index a9bf01a4b..ef660310b 100644 --- a/webcit/addressbook_popup.c +++ b/webcit/addressbook_popup.c @@ -2,6 +2,22 @@ * $Id$ * * AJAX-powered auto-completion + * + * Copyright (c) 2005-2010 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 */ #include "webcit.h" diff --git a/webcit/auth.c b/webcit/auth.c index 2ed2413bd..99e11606d 100644 --- a/webcit/auth.c +++ b/webcit/auth.c @@ -2,6 +2,22 @@ * $Id$ * * WebcitAuth; Handles authentication of users to a Citadel server. + * + * Copyright (c) 1996-2010 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 */ #include "webcit.h" diff --git a/webcit/autocompletion.c b/webcit/autocompletion.c index 70b38dead..20b6cd95a 100644 --- a/webcit/autocompletion.c +++ b/webcit/autocompletion.c @@ -2,6 +2,22 @@ * $Id$ * * ajax-powered autocompletion... + * + * Copyright (c) 1996-2010 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 */ #include "webcit.h" diff --git a/webcit/availability.c b/webcit/availability.c index 8f1e39950..00ee0ac71 100644 --- a/webcit/availability.c +++ b/webcit/availability.c @@ -1,6 +1,21 @@ /* * $Id$ * + * Copyright (c) 1996-2010 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 */ diff --git a/webcit/calendar.c b/webcit/calendar.c index 0c280372f..9211b2bc0 100644 --- a/webcit/calendar.c +++ b/webcit/calendar.c @@ -2,6 +2,22 @@ * $Id$ * * Functions which handle calendar objects and their processing/display. + * + * Copyright (c) 1996-2010 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 */ #include "webcit.h" diff --git a/webcit/calendar_tools.c b/webcit/calendar_tools.c index e5ecf5d6d..100e900ca 100644 --- a/webcit/calendar_tools.c +++ b/webcit/calendar_tools.c @@ -2,6 +2,22 @@ * $Id$ * * Miscellaneous functions which handle calendar components. + * + * Copyright (c) 1996-2010 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 */ #include "webcit.h" diff --git a/webcit/calendar_view.c b/webcit/calendar_view.c index 0d81611a6..a60697a62 100644 --- a/webcit/calendar_view.c +++ b/webcit/calendar_view.c @@ -2,6 +2,22 @@ * $Id$ * * Handles the HTML display of calendar items. + * + * Copyright (c) 1996-2010 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 */ #include "webcit.h" diff --git a/webcit/context_loop.c b/webcit/context_loop.c index efa864f00..7521207b2 100644 --- a/webcit/context_loop.c +++ b/webcit/context_loop.c @@ -6,6 +6,21 @@ * keep track of things. If the HTTP request doesn't belong to any currently * active session, a new session is started. * + * Copyright (c) 1996-2010 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 */ #include "webcit.h" @@ -98,7 +113,7 @@ void do_housekeeping(void) begin_critical_section(S_SPAWNER); while ( (num_threads_executing >= num_threads_existing) - && (num_threads_existing <= MAX_WORKER_THREADS) + && (num_threads_existing < MAX_WORKER_THREADS) ) { spawn_another_worker_thread(); } diff --git a/webcit/cookie_conversion.c b/webcit/cookie_conversion.c index ff9460b52..647ec406b 100644 --- a/webcit/cookie_conversion.c +++ b/webcit/cookie_conversion.c @@ -1,5 +1,21 @@ /* * $Id$ + * + * Copyright (c) 1996-2010 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 */ #include "webcit.h" diff --git a/webcit/crypto.c b/webcit/crypto.c index 344dc6a5a..6618ac1bc 100644 --- a/webcit/crypto.c +++ b/webcit/crypto.c @@ -1,5 +1,21 @@ /* * $Id$ + * + * Copyright (c) 1996-2010 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 */ #include "sysdep.h" diff --git a/webcit/downloads.c b/webcit/downloads.c index 137a6389d..84409acd7 100644 --- a/webcit/downloads.c +++ b/webcit/downloads.c @@ -1,5 +1,21 @@ /* * $Id$ + * + * Copyright (c) 1996-2010 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 */ #include "webcit.h" #include "webserver.h" diff --git a/webcit/event.c b/webcit/event.c index 3d2be8cb7..61f664da9 100644 --- a/webcit/event.c +++ b/webcit/event.c @@ -2,6 +2,22 @@ * $Id$ * * Editing calendar events. + * + * Copyright (c) 1996-2010 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 */ #include "webcit.h" diff --git a/webcit/floors.c b/webcit/floors.c index 287bf2d51..0cb82ce2c 100644 --- a/webcit/floors.c +++ b/webcit/floors.c @@ -1,11 +1,22 @@ /* * $Id$ + * + * Copyright (c) 1996-2010 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 */ -/** - * \defgroup AdminFloor Administrative screens for floor maintenance - * \ingroup CitadelConfig - */ -/*@{*/ #include "webcit.h" #include "webserver.h" @@ -13,11 +24,9 @@ -/** - * \brief Display floor config +/* * Display floor configuration. If prepend_html is not NULL, its contents * will be displayed at the top of the screen. - * \param prepend_html pagetitle to prepend */ void display_floorconfig(StrBuf *prepend_html) { @@ -131,8 +140,8 @@ void display_floorconfig(StrBuf *prepend_html) } -/** - * \brief delete the actual floor +/* + * delete the actual floor */ void delete_floor(void) { int floornum; @@ -156,8 +165,8 @@ void delete_floor(void) { FreeStrBuf(&Buf); } -/** - * \brief tart creating a new floor +/* + * start creating a new floor */ void create_floor(void) { StrBuf *Buf; @@ -179,17 +188,15 @@ void create_floor(void) { } -/** - * \brief rename this floor +/* + * rename this floor */ void rename_floor(void) { StrBuf *Buf; Buf = NewStrBuf(); - serv_printf("EFLR %d|%s", - ibstr("floornum"), - bstr("floorname")); + serv_printf("EFLR %d|%s", ibstr("floornum"), bstr("floorname")); StrBuf_ServGetln(Buf); StrBufCutLeft(Buf, 4); @@ -209,4 +216,3 @@ InitModule_FLOORS WebcitAddUrlHandler(HKEY("create_floor"), "", 0, create_floor, 0); WebcitAddUrlHandler(HKEY("display_floorconfig"), "", 0, _display_floorconfig, 0); } -/*@}*/ diff --git a/webcit/fmt_date.c b/webcit/fmt_date.c index 4384e7dc0..cf2cb0ee1 100644 --- a/webcit/fmt_date.c +++ b/webcit/fmt_date.c @@ -1,5 +1,21 @@ /* * $Id$ + * + * Copyright (c) 1996-2010 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 */ #include "webcit.h" diff --git a/webcit/gettext.c b/webcit/gettext.c index 58facf121..129a8cce5 100644 --- a/webcit/gettext.c +++ b/webcit/gettext.c @@ -1,5 +1,21 @@ /* * $Id$ + * + * Copyright (c) 1996-2010 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 */ #include "webcit.h" @@ -32,7 +48,7 @@ long nLocalesLoaded = 0; locale_t *wc_locales; /**< here we keep the parsed stuff */ #endif -/** Keep information about one locale */ +/* Keep information about one locale */ typedef struct _lang_pref{ char lang[16]; /**< the language locale string */ char region[16]; /**< the region locale string */ @@ -41,15 +57,15 @@ typedef struct _lang_pref{ int selectedlang; /**< is this the selected language? */ } LangStruct; -/* \brief parse browser locale header - * seems as most browsers just do a one after coma value even if more than 10 locales are available. Sample strings: +/* parse browser locale header + * + * seems as most browsers just do a one after comma value even if more than 10 locales are available. Sample strings: * opera: * Accept-Language: sq;q=1.0,de;q=0.9,as;q=0.8,ar;q=0.7,bn;q=0.6,zh-cn;q=0.5,kn;q=0.4,ch;q=0.3,fo;q=0.2,gn;q=0.1,ce;q=0.1,ie;q=0.1 * Firefox * Accept-Language: 'de-de,en-us;q=0.7,en;q=0.3' * Accept-Language: de,en-ph;q=0.8,en-us;q=0.5,de-at;q=0.3 * Accept-Language: de,en-us;q=0.9,it;q=0.9,de-de;q=0.8,en-ph;q=0.7,de-at;q=0.7,zh-cn;q=0.6,cy;q=0.5,ar-om;q=0.5,en-tt;q=0.4,xh;q=0.3,nl-be;q=0.3,cs;q=0.2,sv;q=0.1,tk;q=0.1 - * \param LocaleString the string from the browser http headers */ void httplang_to_locale(StrBuf *LocaleString, wcsession *sess) @@ -121,7 +137,7 @@ void httplang_to_locale(StrBuf *LocaleString, wcsession *sess) ls->region[blen] = '\0'; } - /** area codes are uppercase */ + /* area codes are uppercase */ blen = strlen(&ls->region[0]); for (j = 0; j < blen; j++) { @@ -179,8 +195,8 @@ void httplang_to_locale(StrBuf *LocaleString, wcsession *sess) FreeStrBuf(&SBuf); } -/** - * \brief show the language chooser on the login dialog +/* + * show the language chooser on the login dialog * depending on the browser locale change the sequence of the * language chooser. */ @@ -216,9 +232,8 @@ void tmplput_offer_languages(StrBuf *Target, WCTemplputParams *TP) wc_printf("\n"); } -/** - * \brief Set the selected language for this session. - * \param lang the locale to set. +/* + * Set the selected language for this session. */ void set_selected_language(const char *lang) { #ifdef HAVE_USELOCALE @@ -231,8 +246,8 @@ void set_selected_language(const char *lang) { #endif } -/** - * \brief Activate the selected language for this session. +/* + * Activate the selected language for this session. */ void go_selected_language(void) { #ifdef HAVE_USELOCALE @@ -248,8 +263,8 @@ void go_selected_language(void) { #endif } -/** - * \brief Deactivate the selected language for this session. +/* + * Deactivate the selected language for this session. */ void stop_selected_language(void) { #ifdef HAVE_USELOCALE @@ -262,8 +277,8 @@ void stop_selected_language(void) { locale_t Empty_Locale; #endif -/** - * \brief Create a locale_t for each available language +/* + * Create a locale_t for each available language */ void initialize_locales(void) { int nLocales; @@ -384,21 +399,21 @@ ServerShutdownModule_GETTEXT const char *AvailLang[] = { "C", ""}; -/** \brief dummy for non NLS enabled systems */ +/* dummy for non NLS enabled systems */ void tmplput_offer_languages(StrBuf *Target, WCTemplputParams *TP) { wc_printf("English (US)"); } -/** \brief dummy for non NLS enabled systems */ +/* dummy for non NLS enabled systems */ void set_selected_language(char *lang) { } -/** \brief dummy for non NLS enabled systems */ +/* dummy for non NLS enabled systems */ void go_selected_language(void) { } -/** \brief dummy for non NLS enabled systems */ +/* dummy for non NLS enabled systems */ void stop_selected_language(void) { } diff --git a/webcit/graphics.c b/webcit/graphics.c index e9a2a713a..4d3e48e1d 100644 --- a/webcit/graphics.c +++ b/webcit/graphics.c @@ -2,7 +2,22 @@ * $Id$ * * Handles HTTP upload of graphics files into the system. - * \ingroup WebcitHttpServer + * + * Copyright (c) 1996-2010 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 */ #include "webcit.h" diff --git a/webcit/groupdav_delete.c b/webcit/groupdav_delete.c index e4cb41695..f7ffd4edc 100644 --- a/webcit/groupdav_delete.c +++ b/webcit/groupdav_delete.c @@ -3,6 +3,21 @@ * * Handles GroupDAV DELETE requests. * + * Copyright (c) 2005-2010 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 */ #include "webcit.h" diff --git a/webcit/groupdav_get.c b/webcit/groupdav_get.c index f3f994405..1357d6216 100644 --- a/webcit/groupdav_get.c +++ b/webcit/groupdav_get.c @@ -3,6 +3,22 @@ * * Handles GroupDAV GET requests. * + * + * Copyright (c) 2005-2010 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 */ #include "webcit.h" diff --git a/webcit/groupdav_main.c b/webcit/groupdav_main.c index 313efe83c..bc5286fc8 100644 --- a/webcit/groupdav_main.c +++ b/webcit/groupdav_main.c @@ -3,6 +3,22 @@ * * Entry point for GroupDAV functions * + * + * Copyright (c) 2005-2010 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 */ #include "webcit.h" diff --git a/webcit/groupdav_options.c b/webcit/groupdav_options.c index 1b1f3b904..a5836ea32 100644 --- a/webcit/groupdav_options.c +++ b/webcit/groupdav_options.c @@ -3,6 +3,22 @@ * * Handles DAV OPTIONS requests (experimental -- not required by GroupDAV) * + * + * Copyright (c) 2005-2010 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 */ #include "webcit.h" diff --git a/webcit/groupdav_propfind.c b/webcit/groupdav_propfind.c index d8dfc211e..e3e7a0a93 100644 --- a/webcit/groupdav_propfind.c +++ b/webcit/groupdav_propfind.c @@ -12,6 +12,21 @@ * This makes it difficult to read, but we have discovered clients which * crash when you try to pretty it up. * + * Copyright (c) 2005-2010 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 */ #include "webcit.h" diff --git a/webcit/groupdav_put.c b/webcit/groupdav_put.c index 4e924f2aa..c681575dd 100644 --- a/webcit/groupdav_put.c +++ b/webcit/groupdav_put.c @@ -3,6 +3,21 @@ * * Handles GroupDAV PUT requests. * + * Copyright (c) 2005-2010 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 */ #include "webcit.h" diff --git a/webcit/html2html.c b/webcit/html2html.c index 91bac48ea..4185b1fed 100644 --- a/webcit/html2html.c +++ b/webcit/html2html.c @@ -1,20 +1,31 @@ /* * $Id$ - */ -/** - * \defgroup HTML2HTML Output an HTML message, modifying it slightly to make sure it plays nice + * + * Output an HTML message, modifying it slightly to make sure it plays nice * with the rest of our web framework. - * \ingroup WebcitHttpServer + * + * Copyright (c) 2005-2010 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 */ -/*@{*/ + #include "webcit.h" #include "webserver.h" -/** - * \brief Strip surrounding single or double quotes from a string. - * - * \param s String to be stripped. +/* + * Strip surrounding single or double quotes from a string. */ void stripquotes(char *s) { @@ -32,12 +43,12 @@ void stripquotes(char *s) } -/** - * \brief Check to see if a META tag has overridden the declared MIME character set. +/* + * Check to see if a META tag has overridden the declared MIME character set. * - * \param charset Character set name (left unchanged if we don't do anything) - * \param meta_http_equiv Content of the "http-equiv" portion of the META tag - * \param meta_content Content of the "content" portion of the META tag + * charset Character set name (left unchanged if we don't do anything) + * meta_http_equiv Content of the "http-equiv" portion of the META tag + * meta_content Content of the "content" portion of the META tag */ void extract_charset_from_meta(char *charset, char *meta_http_equiv, char *meta_content) { @@ -78,12 +89,11 @@ void extract_charset_from_meta(char *charset, char *meta_http_equiv, char *meta_ -/** - * \brief Sanitize and enhance an HTML message for display. - * Also convert weird character sets to UTF-8 if necessary. - * Also fixup img src="cid:..." type inline images to fetch the image +/* + * Sanitize and enhance an HTML message for display. + * Also convert weird character sets to UTF-8 if necessary. + * Also fixup img src="cid:..." type inline images to fetch the image * - * \param supplied_charset the input charset as declared in the MIME headers */ void output_html(const char *supplied_charset, int treat_as_wiki, int msgnum, StrBuf *Source, StrBuf *Target) { char buf[SIZ]; @@ -106,11 +116,11 @@ void output_html(const char *supplied_charset, int treat_as_wiki, int msgnum, St StrBuf *BodyArea = NULL; #ifdef HAVE_ICONV iconv_t ic = (iconv_t)(-1) ; - char *ibuf; /**< Buffer of characters to be converted */ - char *obuf; /**< Buffer for converted characters */ - size_t ibuflen; /**< Length of input buffer */ - size_t obuflen; /**< Length of output buffer */ - char *osav; /**< Saved pointer to output buffer */ + char *ibuf; /* Buffer of characters to be converted */ + char *obuf; /* Buffer for converted characters */ + size_t ibuflen; /* Length of input buffer */ + size_t obuflen; /* Length of output buffer */ + char *osav; /* Saved pointer to output buffer */ #endif if (Target == NULL) Target = WC->WBuf; @@ -161,7 +171,7 @@ void output_html(const char *supplied_charset, int treat_as_wiki, int msgnum, St ++ptr; if ((ptr == NULL) || (ptr >= msgend)) break; - /** + /* * Look for META tags. Some messages (particularly in * Asian locales) illegally declare a message's character * set in the HTML instead of in the MIME headers. This @@ -206,7 +216,7 @@ void output_html(const char *supplied_charset, int treat_as_wiki, int msgnum, St } } - /** + /* * Any of these tags cause everything up to and including * the tag to be removed. */ @@ -265,7 +275,7 @@ void output_html(const char *supplied_charset, int treat_as_wiki, int msgnum, St msgstart = ptr; } - /** + /* * Any of these tags cause everything including and following * the tag to be removed. */ @@ -283,7 +293,7 @@ void output_html(const char *supplied_charset, int treat_as_wiki, int msgnum, St strcpy(msg, msgstart); } - /** Now go through the message, parsing tags as necessary. */ + /* Now go through the message, parsing tags as necessary. */ converted_msg = NewStrBufPlain(NULL, content_length + 8192); @@ -327,7 +337,7 @@ void output_html(const char *supplied_charset, int treat_as_wiki, int msgnum, St #endif - /** + /* * At this point, the message has been stripped down to * only the content inside the tags, and has * been converted to UTF-8 if it was originally in a foreign @@ -619,6 +629,8 @@ void UrlizeText(StrBuf* Target, StrBuf *Source, StrBuf *WrkBuf) if (TrailerLen > 0) StrBufAppendBufPlain(Target, end, TrailerLen, 0); } + + void url(char *buf, size_t bufsize) { int len, UrlLen, Offset, TrailerLen, outpos; @@ -693,7 +705,3 @@ void url(char *buf, size_t bufsize) *(buf + Offset + outpos + TrailerLen) = '\0'; } - - - -/*@}*/ diff --git a/webcit/sysdep.c b/webcit/sysdep.c index 432966687..29ac70bcb 100644 --- a/webcit/sysdep.c +++ b/webcit/sysdep.c @@ -1,16 +1,25 @@ /* * $Id$ * - * Citadel "system dependent" stuff. - * See copyright.txt for copyright information. + * WebCit "system dependent" code. * - * Here's where we (hopefully) have most parts of the Citadel server that - * would need to be altered to run the server in a non-POSIX environment. - * - * If we ever port to a different platform and either have multiple - * variants of this file or simply load it up with #ifdefs. + * Copyright (c) 1996-2010 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 */ + #include "sysdep.h" #include #include @@ -296,8 +305,6 @@ void graceful_shutdown_watcher(int signum) { } - - /* * Shut us down the regular way. * signum is the signal we want to forward @@ -416,6 +423,7 @@ void start_daemon(char *pid_file) exit(WEXITSTATUS(status)); } + /* * Spawn an additional worker thread into the pool. */ @@ -439,15 +447,12 @@ void spawn_another_worker_thread() * otherwise the MIME parser crashes on FreeBSD. */ if ((ret = pthread_attr_setstacksize(&attr, 1024 * 1024))) { - lprintf(1, "pthread_attr_setstacksize: %s\n", - strerror(ret)); + lprintf(1, "pthread_attr_setstacksize: %s\n", strerror(ret)); pthread_attr_destroy(&attr); } /* now create the thread */ - if (pthread_create(&SessThread, &attr, - (void *(*)(void *)) worker_entry, NULL) - != 0) { + if (pthread_create(&SessThread, &attr, (void *(*)(void *)) worker_entry, NULL) != 0) { lprintf(1, "Can't create thread: %s\n", strerror(errno)); } @@ -503,6 +508,7 @@ webcit_calc_dirs_n_files(int relh, const char *basedir, int home, char *webcitdi perror("chdir"); } } + void drop_root(uid_t UID) { struct passwd pw, *pwp = NULL;