diff --git a/SNMP_Session-1.13-fix_ivp6.patch b/SNMP_Session-1.13-fix_ivp6.patch new file mode 100644 index 0000000..91d814a --- /dev/null +++ b/SNMP_Session-1.13-fix_ivp6.patch @@ -0,0 +1,12 @@ +diff -u -r SNMP_Session-1.13.orig/lib/SNMP_Session.pm SNMP_Session-1.13/lib/SNMP_Session.pm +--- SNMP_Session-1.13.orig/lib/SNMP_Session.pm 2023-06-05 11:48:19.304310300 +0200 ++++ SNMP_Session-1.13/lib/SNMP_Session.pm 2023-06-05 11:48:48.422475999 +0200 +@@ -622,7 +622,7 @@ + $local_hostname,$ipv4only) = @_; + my($remote_addr,$socket,$sockfamily); + +- $ipv4only = 1 unless defined $ipv4only; ++ $ipv4only = 1 if defined $ipv4only; + $sockfamily = AF_INET; + + $community = 'public' unless defined $community; diff --git a/perl-SNMP_Session.spec b/perl-SNMP_Session.spec index 601dece..e537335 100644 --- a/perl-SNMP_Session.spec +++ b/perl-SNMP_Session.spec @@ -1,11 +1,12 @@ Name: perl-SNMP_Session Version: 1.13 -Release: 33%{?dist} +Release: 34%{?dist} Summary: SNMP support for Perl 5 License: Artistic-2.0 URL: http://code.google.com/p/snmp-session/ Source0: http://snmp-session.googlecode.com/files/SNMP_Session-%{version}.tar.gz +Patch0: SNMP_Session-1.13-fix_ivp6.patch BuildArch: noarch BuildRequires: make BuildRequires: perl-generators @@ -22,6 +23,7 @@ and "set", as well as trap generation and reception. %prep %setup -q -n SNMP_Session-%{version} +%patch -P 0 -p1 %{__perl} -pi -e 's{^#!/usr/local/bin/perl\b}{#!%{__perl}}' test/* chmod -c 644 test/* @@ -47,6 +49,9 @@ make test %changelog +* Mon Jun 05 2023 Michal Josef Špaček - 1.13-34 +- Fix IPv6 functionality of SNMP_Session + * Tue Apr 04 2023 Michal Josef Špaček - 1.13-33 - Fix ipv6 - Modernize spec file