Date: Thu, 23 Jul 2020 06:43:41 +0000 (UTC) From: Muhammad Moinur Rahman <bofh@FreeBSD.org> To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r542917 - in head/mail/dbmail: . files Message-ID: <202007230643.06N6hfNn022907@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: bofh Date: Thu Jul 23 06:43:41 2020 New Revision: 542917 URL: https://svnweb.freebsd.org/changeset/ports/542917 Log: mail/dbmail: Fix imap connection failure - Fix failed to retrieve fd limits PR: 247561 Submitted by: ahicks@p-o.co.uk Added: head/mail/dbmail/files/patch-src_dm__imapsession.c (contents, props changed) head/mail/dbmail/files/patch-src_dm__misc.c (contents, props changed) Modified: head/mail/dbmail/Makefile head/mail/dbmail/files/patch-acinclude.m4 Modified: head/mail/dbmail/Makefile ============================================================================== --- head/mail/dbmail/Makefile Thu Jul 23 05:50:23 2020 (r542916) +++ head/mail/dbmail/Makefile Thu Jul 23 06:43:41 2020 (r542917) @@ -4,6 +4,7 @@ PORTNAME= dbmail PORTVERSION= 3.2.4 DISTVERSIONPREFIX= v +PORTREVISION= 1 CATEGORIES= mail MAINTAINER= bofh@FreeBSD.org Modified: head/mail/dbmail/files/patch-acinclude.m4 ============================================================================== --- head/mail/dbmail/files/patch-acinclude.m4 Thu Jul 23 05:50:23 2020 (r542916) +++ head/mail/dbmail/files/patch-acinclude.m4 Thu Jul 23 06:43:41 2020 (r542917) @@ -1,6 +1,6 @@ ---- acinclude.m4.orig 2015-01-25 10:20:50 UTC +--- acinclude.m4.orig 2020-06-08 07:19:38 UTC +++ acinclude.m4 -@@ -221,7 +221,7 @@ if ( test [ "x$lookforldap" != "xno" ] || test [ "x$lo +@@ -222,7 +222,7 @@ if ( test [ "x$lookforldap" != "xno" ] || test [ "x$lo dnl See if we already have the paths we need in the environment. dnl ...but only if --with-ldap was given without a specific path. if ( test [ "x$lookforldap" = "xyes" ] || test [ "x$lookforauthldap" = "xyes" ] ); then @@ -9,7 +9,7 @@ if test [ "x$LDAPLIB" != "xfailed" ]; then break fi -@@ -233,7 +233,7 @@ if ( test [ "x$lookforldap" != "xno" ] || test [ "x$lo +@@ -234,7 +234,7 @@ if ( test [ "x$lookforldap" != "xno" ] || test [ "x$lo SAVE_CFLAGS=$CFLAGS dnl The headers might be in a funny place, so we need to use -Ipath CFLAGS="$CFLAGS -L$TEST_PATH $LDAPINC" @@ -18,7 +18,7 @@ CFLAGS=$SAVE_CFLAGS if test [ "x$LDAPLIB" != "xfailed" ]; then break 2 -@@ -247,7 +247,7 @@ if ( test [ "x$lookforldap" != "xno" ] || test [ "x$lo +@@ -248,7 +248,7 @@ if ( test [ "x$lookforldap" != "xno" ] || test [ "x$lo AC_MSG_ERROR([Could not find LDAP library.]) else AC_DEFINE([AUTHLDAP], 1, [Define if LDAP will be used.]) @@ -27,7 +27,7 @@ AC_SUBST(LDAPLIB) AC_SUBST(LDAPINC) AUTHALIB="modules/.libs/libauth_ldap.a" -@@ -339,7 +341,7 @@ AC_DEFUN([DM_CHECK_EVENT], [ +@@ -334,7 +334,7 @@ AC_DEFUN([DM_CHECK_EVENT], [ AC_DEFUN([DM_CHECK_SSL], [ AC_CHECK_HEADERS([openssl/ssl.h], @@ -36,7 +36,7 @@ if test [ "x$SSLLIB" = "xfailed" ]; then AC_MSG_ERROR([Could not find OPENSSL library.]) else -@@ -539,15 +541,15 @@ AC_DEFUN([CMU_SOCKETS], [ +@@ -544,15 +544,15 @@ AC_DEFUN([CMU_SOCKETS], [ save_LIBS="$LIBS" SOCKETLIB="" AC_CHECK_FUNC(connect, :, Added: head/mail/dbmail/files/patch-src_dm__imapsession.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/mail/dbmail/files/patch-src_dm__imapsession.c Thu Jul 23 06:43:41 2020 (r542917) @@ -0,0 +1,16 @@ +--- src/dm_imapsession.c.orig 2020-07-23 04:06:59 UTC ++++ src/dm_imapsession.c +@@ -804,9 +804,10 @@ static void _fetch_headers(ImapSession *self, body_fet + "m.mailbox_idnr = %" PRIu64 " " + "AND m.message_idnr %s " + "AND status < %d " +- //"AND n.headername %s IN ('%s') " //old, from the sql point of view is slow +- "having seq %s %d " //patch Cosmin Cioranu, removing the above conditions needs a restriction, patched added +- "ORDER BY message_idnr, seq", ++ //"AND n.headername %s IN ('%s') " //old, from the sql point of view is slow, CC 2020 ++ "GROUP By m.message_idnr, n.headername, v.headervalue " ++ "having seq %s %d " ++ "ORDER BY m.message_idnr, seq", + not?"":fieldorder->str, + DBPFX, DBPFX, DBPFX, DBPFX, + self->mailbox->id, p_string_str(range), Added: head/mail/dbmail/files/patch-src_dm__misc.c ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ head/mail/dbmail/files/patch-src_dm__misc.c Thu Jul 23 06:43:41 2020 (r542917) @@ -0,0 +1,21 @@ +--- src/dm_misc.c.orig 2020-06-29 22:53:45 UTC ++++ src/dm_misc.c +@@ -131,6 +131,10 @@ int drop_privileges(char *newuser, char *newgroup) + + int get_opened_fd_count(void) + { ++#if defined(__FreeBSD__) || defined(__APPLE__) || defined(__SUNPRO_C) || defined(__OpenBSD__) || defined(__NetBSD__) || defined(__DragonFly__) ++ // BSD like systems don't use proc ++ return 0; ++#else + DIR* dir = NULL; + struct dirent* entry = NULL; + char buf[32]; +@@ -147,6 +151,7 @@ int get_opened_fd_count(void) + closedir(dir); + + return fd_count - 2; /* exclude '.' and '..' entries */ ++#endif + } + + void create_unique_id(char *target, uint64_t message_idnr)
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202007230643.06N6hfNn022907>