rpms/dbmail/EL-5 0001-backport-fix-to-prevent-showing-mailboxes-more-than.patch, NONE, 1.1 dbmail-pop3d, 1.3, 1.4 dbmail.cron, 1.1, 1.2 dbmail.spec, 1.19, 1.20
Bernard Johnson
bjohnson at fedoraproject.org
Mon Jul 6 04:57:05 UTC 2009
- Previous message (by thread): rpms/dbmail/devel 0001-backport-fix-to-prevent-showing-mailboxes-more-than.patch, NONE, 1.1 dbmail-pop3d, 1.3, 1.4 dbmail.cron, 1.1, 1.2 dbmail.spec, 1.26, 1.27
- Next message (by thread): rpms/dbmail/F-11 0001-backport-fix-to-prevent-showing-mailboxes-more-than.patch, NONE, 1.1 dbmail-pop3d, 1.3, 1.4 dbmail.cron, 1.1, 1.2 dbmail.spec, 1.26, 1.27
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Author: bjohnson
Update of /cvs/pkgs/rpms/dbmail/EL-5
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv10607/EL-5
Modified Files:
dbmail-pop3d dbmail.cron dbmail.spec
Added Files:
0001-backport-fix-to-prevent-showing-mailboxes-more-than.patch
Log Message:
- patch to remove duplicate email boxes from being listed
- consider cron file a config file
- add -b option to cron job to rebuild body/header/envelope cache tables
- change order of redirection in cron job
- fix typo in dbmail-pop3d that causes LSB info to not be recognized
- add provides for dbmail-sqlite
- conditional to compile with gmime22 when needed
0001-backport-fix-to-prevent-showing-mailboxes-more-than.patch:
--- NEW FILE 0001-backport-fix-to-prevent-showing-mailboxes-more-than.patch ---
>From c8bf103cfd18f3f4a228b299c257ffecac3e0012 Mon Sep 17 00:00:00 2001
From: Paul J Stevens <paul at nfg.nl>
Date: Wed, 1 Jul 2009 18:48:21 +0200
Subject: [PATCH] backport fix to prevent showing mailboxes more than once during LIST/LSUB
---
imapcommands.c | 51 ++++++++++++++++++++++++++++++++-------------------
1 files changed, 32 insertions(+), 19 deletions(-)
diff --git a/imapcommands.c b/imapcommands.c
index 202098b..cd51262 100644
--- a/imapcommands.c
+++ b/imapcommands.c
@@ -678,10 +678,16 @@ int _ic_unsubscribe(struct ImapSession *self)
*
* executes a list command
*/
+static int dm_strcmpdata(gconstpointer a, gconstpointer b, gpointer data UNUSED)
+{
+ return strcmp((const char *)a, (const char *)b);
+}
+
int _ic_list(struct ImapSession *self)
{
imap_userdata_t *ud = (imap_userdata_t *) self->ci->userData;
u64_t *children = NULL;
+ GTree *shown = NULL;
int result;
size_t slen;
unsigned i;
@@ -738,6 +744,8 @@ int _ic_list(struct ImapSession *self)
mb = g_new0(mailbox_t,1);
+ shown = g_tree_new_full((GCompareDataFunc)dm_strcmpdata,NULL,(GDestroyNotify)g_free,NULL);
+
for (i = 0; i < nchildren; i++) {
gboolean show = FALSE;
if ((db_getmailbox_list_result(children[i], ud->userid, mb) != 0))
@@ -778,31 +786,36 @@ int _ic_list(struct ImapSession *self)
show = TRUE;
}
- if (! show) continue;
-
- plist = NULL;
- if (mb->no_select)
- plist = g_list_append(plist, g_strdup("\\noselect"));
- if (mb->no_inferiors)
- plist = g_list_append(plist, g_strdup("\\noinferiors"));
- if (mb->no_children)
- plist = g_list_append(plist, g_strdup("\\hasnochildren"));
- else
- plist = g_list_append(plist, g_strdup("\\haschildren"));
-
- /* show */
- pstring = dbmail_imap_plist_as_string(plist);
- dbmail_imap_session_printf(self, "* %s %s \"%s\" \"%s\"\r\n", thisname,
- pstring, MAILBOX_SEPARATOR, mb->name);
-
- g_list_destroy(plist);
- g_free(pstring);
+ if (show && (! g_tree_lookup(shown, mb->name))) {
+ char *s = g_strdup(mb->name);
+ g_tree_insert(shown, s, s);
+ plist = NULL;
+ if (mb->no_select)
+ plist = g_list_append(plist, g_strdup("\\noselect"));
+ if (mb->no_inferiors)
+ plist = g_list_append(plist, g_strdup("\\noinferiors"));
+ if (mb->no_children)
+ plist = g_list_append(plist, g_strdup("\\hasnochildren"));
+ else
+ plist = g_list_append(plist, g_strdup("\\haschildren"));
+
+ /* show */
+ pstring = dbmail_imap_plist_as_string(plist);
+ dbmail_imap_session_printf(self, "* %s %s \"%s\" \"%s\"\r\n", thisname,
+ pstring, MAILBOX_SEPARATOR, mb->name);
+
+ g_list_destroy(plist);
+ g_free(pstring);
+ }
}
if (children)
g_free(children);
+ if (shown)
+ g_tree_destroy(shown);
+
g_free(pattern);
g_free(mb);
dbmail_imap_session_printf(self, "%s OK %s completed\r\n", self->tag, thisname);
--
1.6.0.4
Index: dbmail-pop3d
===================================================================
RCS file: /cvs/pkgs/rpms/dbmail/EL-5/dbmail-pop3d,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -p -r1.3 -r1.4
--- dbmail-pop3d 3 Feb 2009 22:40:05 -0000 1.3
+++ dbmail-pop3d 6 Jul 2009 04:56:35 -0000 1.4
@@ -7,7 +7,7 @@
# processname: dbmail-pop3d
# pidfile: /var/run/dbmail-pop3d.pid
# config: /etc/dbmail.conf
-## BEGIN INIT INFO
+### BEGIN INIT INFO
# Provides: dbmail-pop3d
# Required-Start: $local_fs $network $syslog
# Should-Start:
Index: dbmail.cron
===================================================================
RCS file: /cvs/pkgs/rpms/dbmail/EL-5/dbmail.cron,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -p -r1.1 -r1.2
--- dbmail.cron 21 Feb 2007 06:35:36 -0000 1.1
+++ dbmail.cron 6 Jul 2009 04:56:35 -0000 1.2
@@ -6,4 +6,4 @@ export LD_LIBRARY_PATH=${LD_LIBRARY_PATH
echo "" >> $LOGFILE
date >> $LOGFILE
-dbmail-util -c -t -u -p -d -y 2>&1 >> $LOGFILE
+dbmail-util -c -t -u -b -p -d -y >> $LOGFILE 2>&1
Index: dbmail.spec
===================================================================
RCS file: /cvs/pkgs/rpms/dbmail/EL-5/dbmail.spec,v
retrieving revision 1.19
retrieving revision 1.20
diff -u -p -r1.19 -r1.20
--- dbmail.spec 3 Feb 2009 22:40:05 -0000 1.19
+++ dbmail.spec 6 Jul 2009 04:56:35 -0000 1.20
@@ -1,17 +1,16 @@
+%if 0%{?fedora} && 0%{?fedora} > 10
+%define with_gmime22 1
+%endif
+
# Package User Registry: http://fedoraproject.org/wiki/PackageUserRegistry
%define registry_uid 38
%define registry_name dbmail
%define services dbmail-imapd dbmail-pop3d dbmail-lmtpd dbmail-timsieved
-# older distros don't have sqlite
-%if 0%{?fedora} && 0%{?fedora} < 4
-%define without_sqlite 1
-%endif
-
Name: dbmail
Version: 2.2.11
-Release: 1%{?dist}
+Release: 5%{?dist}
Summary: A database backed mail storage system
Group: System Environment/Daemons
@@ -27,26 +26,31 @@ Source5: dbmail.cron
Source6: dbmail.logrotate
Source7: README.fedora
+Patch0: 0001-backport-fix-to-prevent-showing-mailboxes-more-than.patch
+
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
-BuildRequires: fileutils, openssl >= 0.9.7a
-BuildRequires: glib2-devel >= 2.8, gmime-devel >= 2.1.19
+%if %{with_gmime22}
+BuildRequires: gmime22-devel >= 2.1.19
+%else
+BuildRequires: gmime-devel >= 2.1.19
+%endif
+
+BuildRequires: fileutils, openssl-devel >= 0.9.7a
+BuildRequires: glib2-devel >= 2.8
BuildRequires: libsieve-devel >= 2.1.13
BuildRequires: mysql-devel >= 4.1.3, postgresql-devel
BuildRequires: openldap-devel
-%if ! 0%{?without_sqlite}
BuildRequires: sqlite-devel >= 3
-%endif
Requires: glib2 >= 2.8, logrotate, initscripts, vixie-cron
Requires: initscripts
Requires: /usr/sbin/sendmail
Requires(pre): fedora-usermgmt
Requires(postun):fedora-usermgmt
-%if ! 0%{?without_sqlite}
Requires: sqlite >= 3
Obsoletes: dbmail-sqlite < 2.2.5
-%endif
+Provides: dbmail-sqlite = %{version}
%description
@@ -56,9 +60,7 @@ storing and retrieving mail messages fro
Currently dbmail supports the following database backends:
MySQL
PostgreSQL
-%if ! 0%{?without_sqlite}
SQLite
-%endif
Please see /usr/share/doc/dbmail-*/README.fedora for specific information on
installation and configuration in Fedora.
@@ -66,6 +68,8 @@ installation and configuration in Fedora
%prep
%setup -q
+%patch0 -p 1 -b .duplicate-email-boxes
+
# we don't need README.solaris and we don't want it caught up in the %%doc
# README* wildcard - but we do want our shiny new README.fedora file to be
# installed
@@ -75,9 +79,7 @@ install -p -m 644 %SOURCE7 .
# make a couple of changes to the default dbmail.conf file:
# 1. default driver/authdriver sqlite/sql (sqlite, if supported)
# 2. effective uid/gid to dbmail/dbmail
-%if ! 0%{?without_sqlite}
sed -i 's/\(^driver\W*=\)\(\W*$\)/\1 sqlite/' dbmail.conf
-%endif
sed -i -e 's,\(^db\W*=\)\(.*$\),\1 %{_localstatedir}/lib/dbmail/dbmail.db,' \
-e 's/\(^authdriver\W*=\)\(\W*$\)/\1 sql/' \
-e 's/\(^EFFECTIVE_USER\W*=\)\(.*$\)/\1 dbmail/' \
@@ -106,9 +108,7 @@ chmod +x %{__find_provides}
--with-ldap \
--with-mysql \
--with-pgsql \
-%if ! 0%{?without_sqlite}
--with-sqlite \
-%endif
--with-sieve
make %{?_smp_mflags}
@@ -183,13 +183,11 @@ fi
%{_libdir}/dbmail/libsort_sieve*
%config(noreplace) %{_sysconfdir}/dbmail.conf
%{_initrddir}/dbmail-*
-%{_sysconfdir}/cron.daily/dbmail
+%config(noreplace) %{_sysconfdir}/cron.daily/dbmail
%config(noreplace) %{_sysconfdir}/logrotate.d/dbmail
-%if ! 0%{?without_sqlite}
%doc sql/sqlite/*
%{_libdir}/dbmail/libsqlite*
%dir %attr(0775,root,dbmail) /var/lib/dbmail
-%endif
%package auth-ldap
Summary: A database backed mail storage system - ldap authentication plugin
@@ -231,6 +229,24 @@ This is the postgresql libraries for dbm
%{_libdir}/dbmail/libpgsql*
%changelog
+* Sun Jul 05 2009 Bernard Johnson <bjohnson at symetrix.com> - 2.2.11-5
+- patch to remove duplicate email boxes from being listed
+- consider cron file a config file
+- add -b option to cron job to rebuild body/header/envelope cache tables
+- change order of redirection in cron job
+- fix typo in dbmail-pop3d that causes LSB info to not be recognized
+- add provides for dbmail-sqlite
+- conditional to compile with gmime22 when needed
+
+* Thu Mar 19 2009 Bernard Johnson <bjohnson at symetrix.com> - 2.2.11-4
+- build agaist old gmime22 (bz #490316)
+
+* Tue Feb 24 2009 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 2.2.11-3
+- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
+
+* Thu Feb 05 2009 Bernard Johnson <bjohnson at symetrix.com> - 2.2.11-2
+- change BR from openssl to openssl-devel
+
* Tue Feb 03 2009 Bernard Johnson <bjohnson at symetrix.com> - 2.2.11-1
- v 2.2.11
- updated summaries
- Previous message (by thread): rpms/dbmail/devel 0001-backport-fix-to-prevent-showing-mailboxes-more-than.patch, NONE, 1.1 dbmail-pop3d, 1.3, 1.4 dbmail.cron, 1.1, 1.2 dbmail.spec, 1.26, 1.27
- Next message (by thread): rpms/dbmail/F-11 0001-backport-fix-to-prevent-showing-mailboxes-more-than.patch, NONE, 1.1 dbmail-pop3d, 1.3, 1.4 dbmail.cron, 1.1, 1.2 dbmail.spec, 1.26, 1.27
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the fedora-extras-commits
mailing list