diff --git a/Fix-ipv6-and-add-backward-compatible-new-networking.patch b/Fix-ipv6-and-add-backward-compatible-new-networking.patch new file mode 100644 index 0000000..cfd9ef3 --- /dev/null +++ b/Fix-ipv6-and-add-backward-compatible-new-networking.patch @@ -0,0 +1,24 @@ +From 599378943bf3cac92fda33fc450d8ac04db41644 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Michal=20Josef=20=C5=A0pa=C4=8Dek?= + +Date: Fri, 5 May 2023 12:14:28 +0200 +Subject: [PATCH] Fix usage of IPv6 + +There were a bad check which break IPv6 functionality +--- + lib/SNMP_Session.pm | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/lib/SNMP_Session.pm b/lib/SNMP_Session.pm +index 9d643ac..eab42df 100644 +--- a/lib/SNMP_Session.pm ++++ b/lib/SNMP_Session.pm +@@ -902,7 +902,7 @@ sub open { + $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/SNMP_Session-1.13.tar.gz b/SNMP_Session-1.13.tar.gz deleted file mode 100644 index 1101c62..0000000 Binary files a/SNMP_Session-1.13.tar.gz and /dev/null differ diff --git a/SNMP_Session-1.16.tar.gz b/SNMP_Session-1.16.tar.gz new file mode 100644 index 0000000..d3f1cd0 Binary files /dev/null and b/SNMP_Session-1.16.tar.gz differ diff --git a/perl-SNMP_Session.spec b/perl-SNMP_Session.spec index ac314a9..335b0e8 100644 --- a/perl-SNMP_Session.spec +++ b/perl-SNMP_Session.spec @@ -1,13 +1,12 @@ Name: perl-SNMP_Session -Version: 1.13 -Release: 21 +Version: 1.16 +Release: 1 Summary: SNMP_Session - SNMP support for Perl 5 License: Artistic 2.0 URL: http://github.com/sleinen/snmp-session/ -# git clone https://github.com/sleinen/snmp-session.git -# git reset --hard ea593f051e258c0730f6ba3836053a010294a728 -# tar zcf SNMP_Session-1.13.tar.gz SNMP_Session-1.13 -Source0: SNMP_Session-%{version}.tar.gz +Source0: https://github.com/sleinen/snmp-session/archive/v%{version}/SNMP_Session-%{version}.tar.gz + +Patch0: Fix-ipv6-and-add-backward-compatible-new-networking.patch BuildArch: noarch @@ -20,7 +19,7 @@ SNMP_Session - SNMP support for Perl 5. %package_help %prep -%autosetup -n SNMP_Session-%{version} -p1 +%autosetup -n snmp-session-%{version} -p1 %{_bindir}/perl -pi -e 's{^#!/usr/local/bin/perl\b}{#!%{__perl}}' test/* chmod 644 test/* @@ -49,9 +48,12 @@ make test %files help %defattr(-,root,root) %doc Artistic index.html test/ -/usr/share/man/man3/Net_SNMP_util.3pm.gz +%{_mandir}/man3/* %changelog +* Sat Sep 09 2023 xu_ping <707078654@qq.com> - 1.16-1 +- Upgrade version to 1.16 + * Thu Sep 10 2020 Ge Wang - 1.13-21 - Modify homepage Url