Package: qpsmtpd
Version: 0.84-8
Tags: patch

If qpsmtpd is running on an IPv6 capable system and the missing 
dependency on IO::Socket::INET6 is fullfilled (see Bug #693103),
qpsmtpd will emit warnings like these on startup:

Starting qpsmtpd: Subroutine Qpsmtpd::TcpServer::pack_sockaddr_in6 redefined
at /usr/share/perl/5.14/Exporter.pm line 67.
 at /usr/share/perl5/Qpsmtpd/TcpServer.pm line 17

This is fixed by the attached patch which was also sent
to upstream. Maybe we can get this fix into the releae still?

Regards,
Michael
--- qpsmtpd-0.84.orig/qpsmtpd-forkserver
+++ qpsmtpd-0.84/qpsmtpd-forkserver
@@ -20,10 +20,6 @@ $| = 1;
 
 my $has_ipv6 = Qpsmtpd::TcpServer::has_ipv6;
 
-if ($has_ipv6) {
-  eval 'use Socket6';
-}
-
 # Configuration
 my $MAXCONN   = 15;                  # max simultaneous connections
 my @PORT;                            # port number(s)
--- qpsmtpd-0.84.orig/qpsmtpd-prefork
+++ qpsmtpd-0.84/qpsmtpd-prefork
@@ -31,10 +31,6 @@ defined $Config{sig_name} || die "No sig
 
 my $has_ipv6 = Qpsmtpd::TcpServer::has_ipv6;
 
-if ($has_ipv6) {
-  use Socket6;
-}
-
 #use Time::HiRes qw(gettimeofday tv_interval);
 
 #get available signals
--- qpsmtpd-0.84.orig/lib/Qpsmtpd/TcpServer.pm
+++ qpsmtpd-0.84/lib/Qpsmtpd/TcpServer.pm
@@ -14,7 +14,7 @@ if (
     # INET6 prior to 2.01 will not work; sorry.
     eval {require IO::Socket::INET6; IO::Socket::INET6->VERSION("2.00");}
     ) {
-    import Socket6;
+    Socket6->import(qw(inet_ntop));
     $has_ipv6=1;
 }
 else {

Reply via email to