Browse Source

fix pflogsumm under OSSP fsl world order

Ralf S. Engelschall 23 years ago
parent
commit
ae4f997a1e
2 changed files with 25 additions and 1 deletions
  1. 20 0
      postfix/pflogsumm.patch
  2. 5 1
      postfix/postfix.spec

+ 20 - 0
postfix/pflogsumm.patch

@@ -0,0 +1,20 @@
+--- pflogsumm.pl.orig	Tue Dec 31 19:30:43 2002
++++ pflogsumm.pl	Fri Jan 10 13:07:39 2003
+@@ -557,7 +557,7 @@
+ 		@{$connTime{$1}} =
+ 		    ($msgYr, $msgMon + 1, $msgDay, $msgHr, $msgMin, $msgSec);
+ 	    } elsif(/: disconnect from /o) {
+-		my ($pid, $hostID) = /\/smtpd\[(\d+)\]: disconnect from (.+)$/o;
++		my ($pid, $hostID) = /\/smtpd\[(\d+)\]: disconnect from (.+)$/o || next;
+ 		if(exists($connTime{$pid})) {
+ 		    $hostID = gimme_domain($hostID);
+ 		    my($d, $h, $m, $s) = Delta_DHMS(@{$connTime{$pid}},
+@@ -1267,7 +1267,7 @@
+     }
+     my ($t_mday, $t_mon) = (localtime($time))[3,4];
+ 
+-    return sprintf("%s %2d", $monthNames[$t_mon], $t_mday);
++    return sprintf("%s %02d", $monthNames[$t_mon], $t_mday);
+ }
+ 
+ # if there's a real domain: uses that.  Otherwise uses the first

+ 5 - 1
postfix/postfix.spec

@@ -38,7 +38,7 @@ Distribution: OpenPKG [BASE]
 Group:        Mail
 License:      IPL
 Version:      %{V_postfix}
-Release:      20030103
+Release:      20030110
 
 #   package options
 %option       with_tls       no
@@ -52,6 +52,7 @@ Source2:      http://jimsun.linxnet.com/downloads/pflogsumm-%{V_pflogsumm}.tar.g
 Source3:      etc.tar
 Source4:      fsl.postfix
 Source5:      rc.postfix
+Patch0:       pflogsumm.patch
 
 #   build information
 Prefix:       %{l_prefix}
@@ -102,6 +103,9 @@ Conflicts:    sendmail, ssmtp, exim
     %{l_patch} -p1 <pfixtls-%{V_tls}/pfixtls.diff
 %endif
 
+    #   apply pflogsumm patch
+    ( cd pflogsumm-%{V_pflogsumm}; %{l_patch} -p0 <%{SOURCE pflogsumm.patch} )
+
 %build
     #   configure Postfix (hard-core part I)
     %{l_shtool} subst \