From 215096b179751304d59b397c6539c3015f291f0f Mon Sep 17 00:00:00 2001 From: Silvan Calarco Date: Sat, 6 Jan 2024 10:26:27 +0100 Subject: [PATCH] patch in Fetchmail handler for mysql/mariadb 5.5 [release 2.93-2mamba;Tue Apr 19 2016] --- postfixadmin-2.93-fetchmail-mariadb-5.5.patch | 11 +++++++++++ postfixadmin-2.93-mariadb-5.5.patch | 12 ++++++++++++ postfixadmin.spec | 9 ++++++++- 3 files changed, 31 insertions(+), 1 deletion(-) create mode 100644 postfixadmin-2.93-fetchmail-mariadb-5.5.patch create mode 100644 postfixadmin-2.93-mariadb-5.5.patch diff --git a/postfixadmin-2.93-fetchmail-mariadb-5.5.patch b/postfixadmin-2.93-fetchmail-mariadb-5.5.patch new file mode 100644 index 0000000..0c1fd09 --- /dev/null +++ b/postfixadmin-2.93-fetchmail-mariadb-5.5.patch @@ -0,0 +1,11 @@ +--- postfixadmin-2.93.orig/ADDITIONS/fetchmail.pl 2015-04-04 16:26:21.000000000 +0200 ++++ postfixadmin-2.93/ADDITIONS/fetchmail.pl 2016-04-20 01:01:48.963998884 +0200 +@@ -83,7 +83,7 @@ + if($db_type eq "Pg") { + $sql_cond = "active = 1 AND date_part('epoch',now())-date_part('epoch',date)"; + } elsif($db_type eq "mysql") { +- $sql_cond = "active = 't' AND unix_timestamp(now())-unix_timestamp(date)"; ++ $sql_cond = "active = '1' AND unix_timestamp(now())-unix_timestamp(date)"; + } + + $sql = " diff --git a/postfixadmin-2.93-mariadb-5.5.patch b/postfixadmin-2.93-mariadb-5.5.patch new file mode 100644 index 0000000..9b8204d --- /dev/null +++ b/postfixadmin-2.93-mariadb-5.5.patch @@ -0,0 +1,12 @@ +diff -Nru postfixadmin-2.93.orig/model/PFAHandler.php postfixadmin-2.93/model/PFAHandler.php +--- postfixadmin-2.93.orig/model/PFAHandler.php 2015-04-06 23:58:58.000000000 +0200 ++++ postfixadmin-2.93/model/PFAHandler.php 2016-04-19 21:45:57.177595553 +0200 +@@ -569,7 +569,7 @@ + $base64_decode = "DECODE(###KEY###, 'base64')"; + } else { + $formatted_date = "DATE_FORMAT(###KEY###, '" . escape_string(Config::Lang('dateformat_mysql')) . "')"; +- $base64_decode = "FROM_BASE64(###KEY###)"; ++ $base64_decode = "###KEY###"; + } + + $colformat = array( diff --git a/postfixadmin.spec b/postfixadmin.spec index d0c4dd7..a1fd8fc 100644 --- a/postfixadmin.spec +++ b/postfixadmin.spec @@ -4,7 +4,7 @@ Name: postfixadmin Version: 2.93 -Release: 1mamba +Release: 2mamba Summary: A Web Based Management tool for Postfix Group: Applications/Web Vendor: openmamba @@ -17,6 +17,8 @@ Source2: %{name}-vacation.conf Patch0: %{name}-2.2.1.1-css_menu_width.patch Patch1: %{name}-2.3-fix_php_path.patch Patch2: postfixadmin-2.91-fetchmail-fix-extra-ssl-options.patch +Patch3: postfixadmin-2.93-mariadb-5.5.patch +Patch4: postfixadmin-2.93-fetchmail-mariadb-5.5.patch License: GPL ## AUTOBUILDREQ-BEGIN BuildRequires: perl-Imap @@ -58,6 +60,8 @@ Postfixadmin support files for cyrus-imap. #%patch0 -p1 #%patch1 -p1 #%patch2 -p1 +%patch3 -p1 +%patch4 -p1 %build @@ -180,6 +184,9 @@ exit 0 %dir %{htmldir}/ADDITIONS/cyrus/* %changelog +* Tue Apr 19 2016 Silvan Calarco 2.93-2mamba +- patch in Fetchmail handler for mysql/mariadb 5.5 + * Sat Oct 10 2015 Automatic Build System 2.93-1mamba - automatic version update by autodist