diff options
author | paul <paul@7b491191-dbf0-0310-aff6-d879d4d69008> | 2007-03-29 09:54:12 +0000 |
---|---|---|
committer | paul <paul@7b491191-dbf0-0310-aff6-d879d4d69008> | 2007-03-29 09:54:12 +0000 |
commit | 9de91382c7afa1e4a6109ac7c699df89a3a95c07 (patch) | |
tree | 51536189da6236c6ebd90ef547268fe1f787b525 | |
parent | e86c0da3df312aaccb25458a736e688abaa092d1 (diff) |
merging git tree
git-svn-id: https://svn.ic-s.nl/svn/dbmail/branches/dbmail_2_2_branch@2486 7b491191-dbf0-0310-aff6-d879d4d69008
76 files changed, 127 insertions, 113 deletions
@@ -1,4 +1,4 @@ -$Id$ + Eelco van Beek (eelco at ic-s dot nl) Roel Rozendaal (roel at ic-s dot nl) @@ -1,4 +1,4 @@ -$Id$ + All bugs should be reported through the mantis bugtracker at http://www.dbmail.org/mantis/ @@ -1,4 +1,4 @@ -/* $Id$ +/* (c) 2000-2004 IC&S, The Netherlands (c) 2004-2006 NFG, The Netherlands */ @@ -1,4 +1,4 @@ -/* $Id$ +/* (c) 2000-2005 IC&S, The Netherlands (c) 2004-2006 NFG Net Facilities Group BV, The Netherlands diff --git a/README.aliases b/README.aliases index fc219d16..ed81b752 100644 --- a/README.aliases +++ b/README.aliases @@ -1,4 +1,4 @@ -$Id$ + DBMail Aliases and Forwards =========================== diff --git a/README.exim b/README.exim index ab110c15..71e6ff7c 100644 --- a/README.exim +++ b/README.exim @@ -1,4 +1,4 @@ -$Id: INSTALL.exim 2153 2006-06-05 15:41:45Z aaron $ + Using DBMail with Exim4 by Thomas Mueller diff --git a/README.ldap b/README.ldap index 411b7ee7..80293de5 100644 --- a/README.ldap +++ b/README.ldap @@ -1,4 +1,4 @@ -$Id$ + Dbmail-2 as of 2.1.0 supports ldap for authentication and delivery information. diff --git a/README.postfix b/README.postfix index 234df077..5732d931 100644 --- a/README.postfix +++ b/README.postfix @@ -1,4 +1,4 @@ -/* $Id: INSTALL.postfix 2153 2006-06-05 15:41:45Z aaron $ */ +/* */ Using DBMail with Postfix diff --git a/README.qmail b/README.qmail index e30e0d7d..1ef55af7 100644 --- a/README.qmail +++ b/README.qmail @@ -1,4 +1,4 @@ -/* $Id: INSTALL.qmail 2153 2006-06-05 15:41:45Z aaron $ */ +/* */ Using DBMail with QMail ======================= diff --git a/README.sieve b/README.sieve index 038c8ff6..ef45b0cf 100644 --- a/README.sieve +++ b/README.sieve @@ -1,4 +1,4 @@ -$Id: $ + DBMail-2 as of 2.1.4 supports the Sieve mail sorting language. The libSieve library is used to provide the core Sieve interpreter: http://libsieve.sf.net/ diff --git a/README.smtp b/README.smtp index af5b1ef5..229a5079 100644 --- a/README.smtp +++ b/README.smtp @@ -1,4 +1,4 @@ -$Id: EXTRAS 1746 2005-04-08 10:05:24Z paul $ + DBMail POP/IMAP before SMTP =========================== diff --git a/README.solaris b/README.solaris index 7576b2a2..a8c0a7db 100644 --- a/README.solaris +++ b/README.solaris @@ -1,7 +1,7 @@ README.solaris -$Id: $ + DBMail is able to produce a very large amount of debugging output if requested. Some of this debug output naturally includes strings that diff --git a/README.usermap b/README.usermap index b19f2f8f..3882e998 100644 --- a/README.usermap +++ b/README.usermap @@ -1,7 +1,7 @@ README.usermap -$Id$ + diff --git a/acinclude.m4 b/acinclude.m4 index b1863ad2..59f3a4a4 100644 --- a/acinclude.m4 +++ b/acinclude.m4 @@ -792,7 +792,7 @@ AC_DEFUN([gl_PREREQ_GETOPT], dnl bsd_sockets.m4--which socket libraries do we need? dnl Derrick Brashear dnl from Zephyr -dnl $Id$ +dnl dnl Hacked on by Rob Earhart to not just toss stuff in LIBS dnl It now puts everything required for sockets into SOCKETLIB diff --git a/check_dbmail_auth.c b/check_dbmail_auth.c index 13e9dd59..52be58cb 100644 --- a/check_dbmail_auth.c +++ b/check_dbmail_auth.c @@ -18,7 +18,7 @@ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * * - * $Id: check_dbmail_common.c 1598 2005-02-23 08:41:02Z paul $ + * * * * diff --git a/check_dbmail_common.c b/check_dbmail_common.c index 780fe474..b7864b33 100644 --- a/check_dbmail_common.c +++ b/check_dbmail_common.c @@ -17,7 +17,7 @@ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * * - * $Id$ + * * * * diff --git a/check_dbmail_db.c b/check_dbmail_db.c index e03705b4..ad6d1e0d 100644 --- a/check_dbmail_db.c +++ b/check_dbmail_db.c @@ -18,7 +18,7 @@ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * * - * $Id: check_dbmail_dsn.c 1598 2005-02-23 08:41:02Z paul $ + * * * * diff --git a/check_dbmail_deliver.c b/check_dbmail_deliver.c index f7f318e5..dbe338c5 100644 --- a/check_dbmail_deliver.c +++ b/check_dbmail_deliver.c @@ -17,7 +17,7 @@ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * * - * $Id$ + * * * * diff --git a/check_dbmail_dsn.c b/check_dbmail_dsn.c index 913af1ba..81973d87 100644 --- a/check_dbmail_dsn.c +++ b/check_dbmail_dsn.c @@ -18,7 +18,7 @@ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * * - * $Id: check_dbmail_dsn.c 1598 2005-02-23 08:41:02Z paul $ + * * * * diff --git a/check_dbmail_imapd.c b/check_dbmail_imapd.c index 71db9dd1..862af261 100644 --- a/check_dbmail_imapd.c +++ b/check_dbmail_imapd.c @@ -17,7 +17,7 @@ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * * - * $Id$ + * * * * diff --git a/check_dbmail_mailbox.c b/check_dbmail_mailbox.c index cba5ddc6..2070b36f 100644 --- a/check_dbmail_mailbox.c +++ b/check_dbmail_mailbox.c @@ -17,7 +17,7 @@ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * * - * $Id: check_dbmail_deliver.c 1829 2005-08-01 14:53:53Z paul $ + * * * * diff --git a/check_dbmail_message.c b/check_dbmail_message.c index 5788b06f..e0a1ff4c 100644 --- a/check_dbmail_message.c +++ b/check_dbmail_message.c @@ -17,7 +17,7 @@ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * * - * $Id$ + * * * * diff --git a/check_dbmail_misc.c b/check_dbmail_misc.c index a2981863..c2e4ddcb 100644 --- a/check_dbmail_misc.c +++ b/check_dbmail_misc.c @@ -18,7 +18,7 @@ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * * - * $Id: check_dbmail_common.c 1598 2005-02-23 08:41:02Z paul $ + * * * * diff --git a/check_dbmail_server.c b/check_dbmail_server.c index 0a634c7d..3ff02824 100644 --- a/check_dbmail_server.c +++ b/check_dbmail_server.c @@ -17,7 +17,7 @@ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * * - * $Id$ + * * * * diff --git a/check_dbmail_user.c b/check_dbmail_user.c index 3dbc87ce..b9106ace 100644 --- a/check_dbmail_user.c +++ b/check_dbmail_user.c @@ -17,7 +17,7 @@ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * * - * $Id: check_dbmail_common.c 1598 2005-02-23 08:41:02Z paul $ + * * * * diff --git a/check_dbmail_util.c b/check_dbmail_util.c index 90807bee..997afcdd 100644 --- a/check_dbmail_util.c +++ b/check_dbmail_util.c @@ -17,7 +17,7 @@ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. * * - * $Id: check_dbmail_common.c 1598 2005-02-23 08:41:02Z paul $ + * * * * @@ -19,7 +19,7 @@ */ /* - * $Id$ + * * \file config.c * \brief read configuration values from a config file */ diff --git a/contrib/mailbox2dbmail/mailbox2dbmail b/contrib/mailbox2dbmail/mailbox2dbmail index 7e04ac62..6cbe64c5 100755 --- a/contrib/mailbox2dbmail/mailbox2dbmail +++ b/contrib/mailbox2dbmail/mailbox2dbmail @@ -2,7 +2,7 @@ # Copyright (C) 2004 Dan Weber <dan at mirrorlynx dot com> # -# $Id$ +# # # This program is free software; you can redistribute it and/or # modify it under the terms of the GNU General Public License @@ -18,7 +18,7 @@ # 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., 675 Mass Ave, Cambridge, MA 02139, USA. -# $Id$ +# import os,sys,getopt,email,email.Errors,mailbox version = "%s version 2.0" %(sys.argv[0],) @@ -1,4 +1,4 @@ -/* $Id$ */ +/* */ /* Copyright (C) 1999-2004 IC & S dbmail@ic-s.nl Copyright (c) 2005-2006 NFG Net Facilities Group BV support@nfg.nl @@ -22,7 +22,7 @@ /** * \file db.c * - * $Id$ + * * * implement database functionality. This used to split out * between MySQL and PostgreSQL, but this is now integrated. diff --git a/dbmail-imapsession.c b/dbmail-imapsession.c index 303c4814..27b9fab9 100644 --- a/dbmail-imapsession.c +++ b/dbmail-imapsession.c @@ -18,7 +18,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -/* $Id$ +/* * * dm_imaputil.c * @@ -403,6 +403,8 @@ static int _imap_session_fetch_parse_partspec(struct ImapSession *self) token = self->args[self->args_idx]; nexttoken = self->args[self->args_idx+1]; + TRACE(TRACE_DEBUG,"token [%s], nexttoken [%s]", token, nexttoken); + dbmail_imap_session_bodyfetch_set_argcnt(self); if (dbmail_imap_session_bodyfetch_get_last_argcnt(self) == 0 || ! MATCH(nexttoken,"]") ) @@ -453,6 +455,7 @@ static int _imap_session_fetch_parse_octet_range(struct ImapSession *self) token[delimpos] = '.'; token[strlen(token) - 1] = '>'; } else { + self->args_idx--; return self->args_idx; } @@ -549,6 +552,8 @@ int dbmail_imap_session_fetch_parse_args(struct ImapSession * self) token = (char *)self->args[self->args_idx]; nexttoken = (char *)self->args[self->args_idx+1]; + TRACE(TRACE_DEBUG,"token [%s], nexttoken [%s]", token, nexttoken); + if (MATCH(token,"]")) { if (ispeek) self->fi->getBodyTotalPeek = 1; @@ -1287,7 +1292,7 @@ int check_state_and_args(struct ImapSession * self, const char *command, int min /* check args */ for (i = 0; i < minargs; i++) { - if (!self->args[i]) { + if (!self->args[self->args_idx+i]) { /* error: need more args */ dbmail_imap_session_printf(self, "%s BAD missing argument%s to %s\r\n", self->tag, @@ -1296,7 +1301,7 @@ int check_state_and_args(struct ImapSession * self, const char *command, int min } } - for (i = 0; self->args[i]; i++); + for (i = 0; self->args[self->args_idx+i]; i++); if (maxargs && (i > maxargs)) { /* error: too many args */ @@ -1657,9 +1662,9 @@ int dbmail_imap_session_mailbox_status(struct ImapSession * self, gboolean updat } /* msg counts */ if ((!update) || (ud->mailbox.exists < mb.exists)) // only increments - dbmail_imap_session_printf(self, "* %u EXISTS\r\n", exists); + dbmail_imap_session_printf(self, "* %llu EXISTS\r\n", exists); if ((!update) || (ud->mailbox.recent != mb.recent)) - dbmail_imap_session_printf(self, "* %u RECENT\r\n", recent); + dbmail_imap_session_printf(self, "* %llu RECENT\r\n", recent); if (msginfo) { oldmsginfo = self->msginfo; diff --git a/dbmail-mailbox.c b/dbmail-mailbox.c index b3d017b6..c6ba324d 100644 --- a/dbmail-mailbox.c +++ b/dbmail-mailbox.c @@ -1077,7 +1077,7 @@ static gboolean _do_sort(GNode *node, struct DbmailMailbox *self) return FALSE; q = g_string_new(""); - g_string_printf(q, "SELECT message_idnr FROM %smessages m " + g_string_printf(q, "SELECT DISTINCT(message_idnr) FROM %smessages m " "LEFT JOIN %sphysmessage p ON m.physmessage_id=p.id " "%s" "WHERE m.mailbox_idnr = %llu AND m.status IN (%d,%d) " diff --git a/dbmail-message.c b/dbmail-message.c index b2246a9b..24b0453b 100644 --- a/dbmail-message.c +++ b/dbmail-message.c @@ -1,5 +1,5 @@ /* - $Id$ + Copyright (c) 2004-2006 NFG Net Facilities Group BV support@nfg.nl diff --git a/dbmail-user.c b/dbmail-user.c index 6abc9c8b..00d0219a 100644 --- a/dbmail-user.c +++ b/dbmail-user.c @@ -17,7 +17,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -/* $Id: user.c 1665 2005-03-12 17:42:59Z paul $ +/* * This is the dbmail-user program * It makes adding users easier */ @@ -5,7 +5,7 @@ * * (c) 2005 Aaron Stone <aaron@serendipity.cx> * - * $Id: $ + * */ #include <gmodule.h> diff --git a/debian/README.Debian b/debian/README.Debian index 39a02a32..dd9ac288 100644 --- a/debian/README.Debian +++ b/debian/README.Debian @@ -1,7 +1,7 @@ dbmail for Debian -$Id$ + ----------------- Before you can run dbmail you will have to create the database, @@ -18,7 +18,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -/* $Id$ +/* * * Debugging and memory checking functions */ diff --git a/dm_imaputil.c b/dm_imaputil.c index 37784b1e..8b2b72ac 100644 --- a/dm_imaputil.c +++ b/dm_imaputil.c @@ -18,7 +18,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -/* $Id: dm_imaputil.c 1878 2005-09-04 06:34:44Z paul $ +/* * * dm_imaputil.c * @@ -1,5 +1,5 @@ /* - $Id: md5.c 1891 2005-10-03 10:01:21Z paul $ + Copyright (C) 1999-2004 IC & S dbmail@ic-s.nl @@ -1,7 +1,7 @@ /* Delivery User Functions * Aaron Stone, 9 Feb 2004 */ /* - $Id$ + Copyright (C) 2004 Aaron Stone aaron at serendipity dot cx @@ -17,7 +17,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -/* $Id: user.c 1891 2005-10-03 10:01:21Z paul $ +/* * This is the dbmail-user program * It makes adding users easier * @@ -18,7 +18,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -/* $Id$ +/* * imap4.c * * implements an IMAP 4 rev 1 server. diff --git a/imapcommands.c b/imapcommands.c index 180e6feb..11d43ad6 100644 --- a/imapcommands.c +++ b/imapcommands.c @@ -18,7 +18,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -/* $Id$ +/* * * imapcommands.c * @@ -138,7 +138,7 @@ int _ic_login(struct ImapSession *self) return 1; create_current_timestring(×tring); - if ((result = dbmail_imap_session_handle_auth(self, self->args[0], self->args[1]))) + if ((result = dbmail_imap_session_handle_auth(self, self->args[self->args_idx], self->args[self->args_idx+1]))) return result; if (imap_before_smtp) db_log_ip(self->ci->ip_src); @@ -169,7 +169,7 @@ int _ic_authenticate(struct ImapSession *self) create_current_timestring(×tring); /* check authentication method */ - if (strcasecmp(self->args[0], "login") != 0) { + if (strcasecmp(self->args[self->args_idx], "login") != 0) { dbmail_imap_session_printf(self, "%s NO Invalid authentication mechanism specified\r\n", self->tag); @@ -234,7 +234,7 @@ int _ic_select(struct ImapSession *self) if (!check_state_and_args(self, "SELECT", 1, 1, IMAPCS_AUTHENTICATED)) return 1; /* error, return */ - mailbox = self->args[0]; + mailbox = self->args[self->args_idx]; if ((result = dbmail_imap_session_mailbox_open(self, mailbox))) return result; @@ -260,7 +260,7 @@ int _ic_select(struct ImapSession *self) break; default: TRACE(TRACE_ERROR, "detected invalid permission mode for mailbox %llu ('%s')", - ud->mailbox.uid, self->args[0]); + ud->mailbox.uid, self->args[self->args_idx]); dbmail_imap_session_printf(self, "* BYE fatal: detected invalid mailbox settings\r\n"); @@ -288,7 +288,7 @@ int _ic_examine(struct ImapSession *self) if (!check_state_and_args(self, "EXAMINE", 1, 1, IMAPCS_AUTHENTICATED)) return 1; - mailbox = self->args[0]; + mailbox = self->args[self->args_idx]; if ((result = dbmail_imap_session_mailbox_open(self, mailbox))) return result; @@ -322,7 +322,7 @@ int _ic_create(struct ImapSession *self) return 1; /* Create the mailbox and its parents. */ - result = db_mailbox_create_with_parents(self->args[0], BOX_COMMANDLINE, ud->userid, &mboxid, &message); + result = db_mailbox_create_with_parents(self->args[self->args_idx], BOX_COMMANDLINE, ud->userid, &mboxid, &message); if (result > 0) { dbmail_imap_session_printf(self, "%s NO %s\r\n", self->tag, message); @@ -1644,13 +1644,13 @@ int _ic_copy(struct ImapSession *self) mailbox_t destmbox; cmd_copy_t cmd; - bzero(&destmbox, sizeof(destmbox)); + memset(&destmbox, 0, sizeof(destmbox)); if (!check_state_and_args(self, "COPY", 2, 2, IMAPCS_SELECTED)) return 1; /* error, return */ /* check if destination mailbox exists */ - if (db_findmailbox(self->args[1], ud->userid, &destmboxid) == -1) { + if (db_findmailbox(self->args[self->args_idx+1], ud->userid, &destmboxid) == -1) { dbmail_imap_session_printf(self, "* BYE internal dbase error\r\n"); return -1; /* fatal */ } @@ -1703,7 +1703,7 @@ int _ic_copy(struct ImapSession *self) self->ids = NULL; } - self->ids = dbmail_mailbox_get_set(self->mailbox,self->args[0],self->use_uid); + self->ids = dbmail_mailbox_get_set(self->mailbox,self->args[self->args_idx],self->use_uid); if (g_tree_nnodes(self->ids)==0) { dbmail_imap_session_printf(self, "%s BAD invalid message range specified\r\n", self->tag); @@ -1750,22 +1750,22 @@ int _ic_uid(struct ImapSession *self) self->use_uid = 1; /* set global var to make clear we will be using UID's */ /* ACL rights for UID are handled by the other functions called below */ - if (MATCH(self->args[0], "fetch")) { + if (MATCH(self->args[self->args_idx], "fetch")) { self->args_idx++; result = _ic_fetch(self); - } else if (MATCH(self->args[0], "copy")) { + } else if (MATCH(self->args[self->args_idx], "copy")) { self->args_idx++; result = _ic_copy(self); - } else if (MATCH(self->args[0], "store")) { + } else if (MATCH(self->args[self->args_idx], "store")) { self->args_idx++; result = _ic_store(self); - } else if (MATCH(self->args[0], "search")) { + } else if (MATCH(self->args[self->args_idx], "search")) { self->args_idx++; result = _ic_search(self); - } else if (MATCH(self->args[0], "sort")) { + } else if (MATCH(self->args[self->args_idx], "sort")) { self->args_idx++; result = _ic_sort(self); - } else if (MATCH(self->args[0], "thread")) { + } else if (MATCH(self->args[self->args_idx], "thread")) { self->args_idx++; result = _ic_thread(self); } else { @@ -1820,7 +1820,7 @@ int _ic_getquotaroot(struct ImapSession *self) if (!check_state_and_args(self, "GETQUOTAROOT", 1, 1, IMAPCS_AUTHENTICATED)) return 1; /* error, return */ - root = quota_get_quotaroot(ud->userid, self->args[0], &errormsg); + root = quota_get_quotaroot(ud->userid, self->args[self->args_idx], &errormsg); if (root == NULL) { dbmail_imap_session_printf(self, "%s NO %s\r\n", self->tag, errormsg); return 1; @@ -1832,7 +1832,7 @@ int _ic_getquotaroot(struct ImapSession *self) return 1; } - dbmail_imap_session_printf(self, "* QUOTAROOT \"%s\" \"%s\"\r\n", self->args[0], + dbmail_imap_session_printf(self, "* QUOTAROOT \"%s\" \"%s\"\r\n", self->args[self->args_idx], quota->root); send_quota(self, quota); quota_free(quota); @@ -1855,7 +1855,7 @@ int _ic_getquota(struct ImapSession *self) if (!check_state_and_args(self, "GETQUOTA", 1, 1, IMAPCS_AUTHENTICATED)) return 1; /* error, return */ - quota = quota_get_quota(ud->userid, self->args[0], &errormsg); + quota = quota_get_quota(ud->userid, self->args[self->args_idx], &errormsg); if (quota == NULL) { dbmail_imap_session_printf(self, "%s NO %s\r\n", self->tag, errormsg); return 1; @@ -1900,7 +1900,7 @@ int _ic_setacl(struct ImapSession *self) if (!check_state_and_args(self, "SETACL", 3, 3, IMAPCS_AUTHENTICATED)) return 1; - result = imap_acl_pre_administer(self->args[0], self->args[1], ud->userid, + result = imap_acl_pre_administer(self->args[self->args_idx], self->args[self->args_idx+1], ud->userid, &mboxid, &targetuserid); if (result == -1) { dbmail_imap_session_printf(self, "* BYE internal database error\r\n"); @@ -1918,7 +1918,7 @@ int _ic_setacl(struct ImapSession *self) return 1; } // set the new acl - if (acl_set_rights(targetuserid, mboxid, self->args[2]) < 0) { + if (acl_set_rights(targetuserid, mboxid, self->args[self->args_idx+2]) < 0) { dbmail_imap_session_printf(self, "* BYE internal database error\r\n"); return -1; } @@ -1939,7 +1939,7 @@ int _ic_deleteacl(struct ImapSession *self) if (!check_state_and_args(self, "DELETEACL", 2, 2, IMAPCS_AUTHENTICATED)) return 1; - if (imap_acl_pre_administer(self->args[0], self->args[1], ud->userid, + if (imap_acl_pre_administer(self->args[self->args_idx], self->args[self->args_idx+1], ud->userid, &mboxid, &targetuserid) == -1) { dbmail_imap_session_printf(self, "* BYE internal dbase error\r\n"); return -1; @@ -1974,7 +1974,7 @@ int _ic_getacl(struct ImapSession *self) if (!check_state_and_args(self, "GETACL", 1, 1, IMAPCS_AUTHENTICATED)) return 1; - result = db_findmailbox(self->args[0], ud->userid, &mboxid); + result = db_findmailbox(self->args[self->args_idx], ud->userid, &mboxid); if (result == -1) { dbmail_imap_session_printf(self, "* BYE internal database error\r\n"); return -1; @@ -1989,7 +1989,7 @@ int _ic_getacl(struct ImapSession *self) return -1; } - dbmail_imap_session_printf(self, "* ACL \"%s\" %s\r\n", self->args[0], acl_string); + dbmail_imap_session_printf(self, "* ACL \"%s\" %s\r\n", self->args[self->args_idx], acl_string); dm_free(acl_string); dbmail_imap_session_printf(self, "%s OK GETACL completed\r\n", self->tag); return 0; @@ -2008,7 +2008,7 @@ int _ic_listrights(struct ImapSession *self) if (!check_state_and_args(self, "LISTRIGHTS", 2, 2, IMAPCS_AUTHENTICATED)) return 1; - result = imap_acl_pre_administer(self->args[0], self->args[1], ud->userid, + result = imap_acl_pre_administer(self->args[self->args_idx], self->args[self->args_idx+1], ud->userid, &mboxid, &targetuserid); if (result == -1) { dbmail_imap_session_printf(self, "* BYE internal database error\r\n"); @@ -2035,7 +2035,7 @@ int _ic_listrights(struct ImapSession *self) } dbmail_imap_session_printf(self, "* LISTRIGHTS \"%s\" %s %s\r\n", - self->args[0], self->args[1], listrights_string); + self->args[self->args_idx], self->args[self->args_idx+1], listrights_string); dbmail_imap_session_printf(self, "%s OK LISTRIGHTS completed\r\n", self->tag); dm_free(listrights_string); return 0; @@ -2052,7 +2052,7 @@ int _ic_myrights(struct ImapSession *self) if (!check_state_and_args(self, "LISTRIGHTS", 1, 1, IMAPCS_AUTHENTICATED)) return 1; - result = db_findmailbox(self->args[0], ud->userid, &mboxid); + result = db_findmailbox(self->args[self->args_idx], ud->userid, &mboxid); if (result == -1) { dbmail_imap_session_printf(self, "* BYE internal database error\r\n"); return -1; @@ -2068,7 +2068,7 @@ int _ic_myrights(struct ImapSession *self) return -1; } - dbmail_imap_session_printf(self, "* MYRIGHTS \"%s\" %s\r\n", self->args[0], + dbmail_imap_session_printf(self, "* MYRIGHTS \"%s\" %s\r\n", self->args[self->args_idx], myrights_string); dm_free(myrights_string); dbmail_imap_session_printf(self, "%s OK MYRIGHTS complete\r\n", self->tag); @@ -19,7 +19,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -/* $Id$ +/* * * imapd.c * @@ -18,7 +18,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -/* $Id$ +/* * * functions to create lists and add/delete items */ @@ -17,7 +17,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -/* $Id$ +/* * * implementation for lmtp commands according to RFC 1081 */ @@ -18,7 +18,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -/* $Id$ +/* * * lmtpd.c * @@ -18,7 +18,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -/* $Id$ +/* * * main file for dbmail-smtp */ diff --git a/maintenance.c b/maintenance.c index 1493adfb..e6a3dbda 100644 --- a/maintenance.c +++ b/maintenance.c @@ -18,7 +18,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -/* $Id$ +/* * * This is the dbmail housekeeping program. * It checks the integrity of the database and does a cleanup of all @@ -1,5 +1,5 @@ /* - $Id$ + Copyright (C) 1999-2004 IC & S dbmail@ic-s.nl Copyright (c) 2005-2006 NFG Net Facilities Group BV support@nfg.nl @@ -18,7 +18,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -/* $Id$ +/* * * Miscelaneous functions */ diff --git a/modules/Makefile.am b/modules/Makefile.am index 973015f9..99a34e15 100644 --- a/modules/Makefile.am +++ b/modules/Makefile.am @@ -1,4 +1,4 @@ -# $Id: Makefile.am 1920 2005-11-26 08:32:15Z aaron $ +# # Copyright (C) 1999-2004 IC & S dbmail@ic-s.nl # # This program is free software; you can redistribute it and/or diff --git a/modules/Makefile.in b/modules/Makefile.in index 50198227..082bd4f0 100644 --- a/modules/Makefile.in +++ b/modules/Makefile.in @@ -14,7 +14,7 @@ @SET_MAKE@ -# $Id: Makefile.am 1920 2005-11-26 08:32:15Z aaron $ +# # Copyright (C) 1999-2004 IC & S dbmail@ic-s.nl # # This program is free software; you can redistribute it and/or diff --git a/modules/authldap.c b/modules/authldap.c index dd5df08d..095342da 100644 --- a/modules/authldap.c +++ b/modules/authldap.c @@ -19,7 +19,7 @@ */ /* - * $Id$ + * * * User authentication functions for LDAP. */ #ifdef HAVE_CONFIG_H diff --git a/modules/sortnull.c b/modules/sortnull.c index 0a96cb51..59cefe14 100644 --- a/modules/sortnull.c +++ b/modules/sortnull.c @@ -1,4 +1,4 @@ -/* $Id: sortsieve.c 1912 2005-11-19 02:29:41Z aaron $ +/* Copyright (C) 1999-2004 Aaron Stone aaron at serendipity dot cx diff --git a/modules/sortsieve.c b/modules/sortsieve.c index 3dc9ff6d..50adf706 100644 --- a/modules/sortsieve.c +++ b/modules/sortsieve.c @@ -1,4 +1,4 @@ -/* $Id: sortsieve.c 1912 2005-11-19 02:29:41Z aaron $ +/* Copyright (C) 1999-2004 Aaron Stone aaron at serendipity dot cx @@ -17,7 +17,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -/* $Id$ +/* * * Functions for reading the pipe from the MTA */ @@ -18,7 +18,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -/* $Id$ +/* * * implementation for pop3 commands according to RFC 1081 */ @@ -19,7 +19,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -/* $Id$ +/* * * pop3d.c * @@ -1,5 +1,5 @@ /* - $Id$ + Copyright (C) 1999-2004 IC & S dbmail@ic-s.nl Copyright (c) 2005-2006 NFG Net Facilities Group BV support@nfg.nl @@ -1,5 +1,5 @@ /* - $Id$ + Copyright (C) 1999-2004 IC & S dbmail@ic-s.nl Copyright (c) 2004-2006 NFG Net Facilities Group BV support@nfg.nl diff --git a/serverchild.c b/serverchild.c index 3dadb32e..dbe938fe 100644 --- a/serverchild.c +++ b/serverchild.c @@ -21,7 +21,7 @@ /* * serverchild.c * - * $Id$ + * * * function implementations of server children code (connection handling) */ diff --git a/serverparent.c b/serverparent.c index 625eb2f3..ecc594d9 100644 --- a/serverparent.c +++ b/serverparent.c @@ -19,7 +19,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -/* $Id: serverparent.c 2199 2006-07-18 11:07:53Z paul $ +/* * * serverparent.c * @@ -17,7 +17,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -/* $Id$ +/* * This is dbmail-sievecmd, which provides * a command line interface to the sievescripts */ @@ -16,7 +16,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -/* $Id: sort.c 2199 2006-07-18 11:07:53Z paul $ +/* * * Central switching station for email on its way to be delivered. * From here we call out to the sorting module, if applicable, to diff --git a/sql/mysql/create_tables.mysql b/sql/mysql/create_tables.mysql index b2ad7284..a635f566 100644 --- a/sql/mysql/create_tables.mysql +++ b/sql/mysql/create_tables.mysql @@ -23,7 +23,7 @@ # This file was originally created by Paul Stevens and added # to dbmail on August 27th, 2003. # -# $Id$ +# SET FOREIGN_KEY_CHECKS=0; diff --git a/sql/mysql/migrate_from_1.x_to_2.0_innodb.mysql b/sql/mysql/migrate_from_1.x_to_2.0_innodb.mysql index 516536b0..8f9cf313 100644 --- a/sql/mysql/migrate_from_1.x_to_2.0_innodb.mysql +++ b/sql/mysql/migrate_from_1.x_to_2.0_innodb.mysql @@ -15,7 +15,7 @@ # along with this program; if not, write to the Free Software # Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. -# $Id$ +# # SQL for upgrading from dbmail-1.2 to dbmail-2.0 # This script was written by Paul J Stevens. Some changes were made # by Ilja Booij @ IC & S to make it work with the optional tables from diff --git a/sql/postgresql/create_tables.pgsql b/sql/postgresql/create_tables.pgsql index d6c42be0..3a75925d 100644 --- a/sql/postgresql/create_tables.pgsql +++ b/sql/postgresql/create_tables.pgsql @@ -16,7 +16,7 @@ along with this program; if not, write to the Free Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -/* $Id$ +/* */ BEGIN TRANSACTION; diff --git a/sql/postgresql/migrate_from_1.x_to_2.0.pgsql b/sql/postgresql/migrate_from_1.x_to_2.0.pgsql index 424ca540..e036842d 100644 --- a/sql/postgresql/migrate_from_1.x_to_2.0.pgsql +++ b/sql/postgresql/migrate_from_1.x_to_2.0.pgsql @@ -18,7 +18,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ --- $Id$ +-- /* first start a transaction to possibly create the auto_replies and auto_notifications tables, which might, or might not be present. diff --git a/sql/postgresql/migrate_from_2.0_to_2.2.pgsql b/sql/postgresql/migrate_from_2.0_to_2.2.pgsql index 45288cd5..5a4dbfaf 100644 --- a/sql/postgresql/migrate_from_2.0_to_2.2.pgsql +++ b/sql/postgresql/migrate_from_2.0_to_2.2.pgsql @@ -25,7 +25,7 @@ COMMIT; -- -- modify dbmail schema to support header caching. -- --- $Id: add_header_tables.psql 1634 2005-03-07 16:13:21Z paul $ +-- -- -- -- store all headers by storing all headernames and headervalues in separate @@ -185,7 +185,7 @@ CREATE UNIQUE INDEX replycache_1 ON dbmail_replycache USING btree (to_addr, from -- -- Add tables and columns to hold Sieve scripts. -- --- $Id: add_header_tables.mysql 1634 2005-03-07 16:13:21Z paul $ +-- -- BEGIN TRANSACTION; diff --git a/sql/sqlite/create_tables.sqlite b/sql/sqlite/create_tables.sqlite index f0bac40c..385d29b4 100644 --- a/sql/sqlite/create_tables.sqlite +++ b/sql/sqlite/create_tables.sqlite @@ -15,7 +15,7 @@ -- 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., 675 Mass Ave, Cambridge, MA 02139, USA. --- $Id$ +-- BEGIN TRANSACTION; diff --git a/test-scripts/testimap.py b/test-scripts/testimap.py index 9cd563d0..ac0685c4 100755 --- a/test-scripts/testimap.py +++ b/test-scripts/testimap.py @@ -16,7 +16,7 @@ # 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., 675 Mass Ave, Cambridge, MA 02139, USA. -# $Id$ +# # For a protocol trace set to 4 DEBUG = 0 @@ -220,6 +220,13 @@ class testImapServer(unittest.TestCase): self.assertEquals(self.o.fetch("1:*","(Flags)")[0],'OK') id=1 + # OE query + result=self.o.fetch(id,"(BODY.PEEK[HEADER.FIELDS (References X-Ref X-Priority X-MSMail-Priority X-MSOESRec Newsgroups)] ENVELOPE RFC822.SIZE UID FLAGS INTERNALDATE)") + self.assertEquals(len(result[1]),5) + expect=[(' (("somewhere.foo" NIL "somewher" "foo.org")) (("somewhere.foo" NIL "somewher" "foo.org")) (("somewhere.foo" NIL "somewher" "foo.org")) (("test user" NIL "testuser" "foo.org")) ((NIL NIL "somewher" "foo.org")(NIL NIL "other" "bar.org")) NIL {84}', '"Message from "Test User" <testuser@test.org> of "Sat,\t14 Dec 2002 09:17:00 CST."'), (' {36}', '<"114.5862946l.21522l.0l"@localhost>'), (') BODY[HEADER.FIELDS (References X-Ref X-Priority X-MSMail-Priority X-MSOESRec Newsgroups)] {2}', '\r\n'), ')'] + self.assertEquals(result[1][1:],expect) + self.assertEquals(result[0],'OK') + # fetch complete message. order and number of headers may differ result1 = self.o.fetch(id,"(UID BODY[])") result2 = self.o.fetch(id,"(UID RFC822)") @@ -249,12 +256,9 @@ class testImapServer(unittest.TestCase): self.assertEquals(result[0],'OK') self.assertEquals(result[1][0][1][-2:],'\r\n') - # OE query - result=self.o.fetch(id,"(BODY.PEEK[HEADER.FIELDS (References X-Ref X-Priority X-MSMail-Priority X-MSOESRec Newsgroups)] ENVELOPE RFC822.SIZE UID FLAGS INTERNALDATE)") - self.assertEquals(result[0],'OK') - # TB query result=self.o.fetch(id,"(UID RFC822.SIZE FLAGS BODY.PEEK[HEADER.FIELDS (From To Cc Subject Date Message-ID Priority X-Priority References Newsgroups In-Reply-To Content-Type)])") + print result self.assertEquals(result[0],'OK') # test big folder full fetch @@ -566,6 +570,10 @@ class testImapServer(unittest.TestCase): self.assertEquals(len(result[1]) < 10, True) result=self.o.uid('FETCH','10:*', 'FLAGS') self.assertEquals(len(result[1]) > 0, True) + print self.o.create('testuidcopy') + result=self.o.uid('COPY','*','testuidcopy') + print result + self.assertEquals(result[0],'OK') def testUnsubscribe(self): """ diff --git a/test-scripts/testpop.py b/test-scripts/testpop.py index 8fd9e0bf..905874d7 100755 --- a/test-scripts/testpop.py +++ b/test-scripts/testpop.py @@ -16,7 +16,7 @@ # 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., 675 Mass Ave, Cambridge, MA 02139, USA. -# $Id: testimap.py 1897 2005-10-11 11:59:17Z paul $ +# # For a protocol trace set to 4 DEBUG = 0 diff --git a/test-scripts/testsort.imap b/test-scripts/testsort.imap index 04c275cc..c85bf59c 100644 --- a/test-scripts/testsort.imap +++ b/test-scripts/testsort.imap @@ -10,3 +10,4 @@ a09 UID SORT (ARRIVAL FROM) US-ASCII ALL a10 UID SORT (REVERSE ARRIVAL FROM) US-ASCII ALL a11 UID SORT (REVERSE ARRIVAL FROM) US-ASCII SUBJECT "some test" a12 SORT (REVERSE DATE) utf-8 SUBJECT "lars hase" +a13 UID SORT 1:* (TO) UTF-8 ALL @@ -1,4 +1,4 @@ -/* $Id$ +/* Copyright (C) 1999-2004 Aaron Stone aaron at serendipity dot cx diff --git a/timsieved.c b/timsieved.c index d25b815e..5a864359 100644 --- a/timsieved.c +++ b/timsieved.c @@ -1,4 +1,4 @@ -/* $Id$ +/* Copyright (C) 2004 Aaron Stone aaron at serendipity dot cx @@ -18,7 +18,7 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ -/* $Id$ +/* * This is the dbmail-user program * It makes adding users easier * |