rpms/net-snmp/devel net-snmp-5.2.2-tcp-partial-packet.patch, NONE, 1.1 net-snmp.spec, 1.55, 1.56
fedora-cvs-commits at redhat.com
fedora-cvs-commits at redhat.com
Wed Dec 7 08:48:01 UTC 2005
Author: rvokal
Update of /cvs/dist/rpms/net-snmp/devel
In directory cvs.devel.redhat.com:/tmp/cvs-serv18533
Modified Files:
net-snmp.spec
Added Files:
net-snmp-5.2.2-tcp-partial-packet.patch
Log Message:
- fix read problem on stream sockets (net-snmp bz#1337534)
net-snmp-5.2.2-tcp-partial-packet.patch:
snmp_api.c | 10 ++++++++--
1 files changed, 8 insertions(+), 2 deletions(-)
--- NEW FILE net-snmp-5.2.2-tcp-partial-packet.patch ---
Index: snmplib/snmp_api.c
===================================================================
RCS file: /cvsroot/net-snmp/net-snmp/snmplib/snmp_api.c,v
retrieving revision 5.68.2.15
diff -u -p -r5.68.2.15 snmp_api.c
--- snmplib/snmp_api.c 10 Oct 2005 12:01:27 -0000 5.68.2.15
+++ snmplib/snmp_api.c 2 Dec 2005 22:49:14 -0000
@@ -5562,12 +5562,18 @@ _sess_read(void *sessp, fd_set * fdset)
if (pdulen > isp->packet_len || pdulen == 0) {
/*
- * We don't have a complete packet yet. Return, and wait for
- * more data to arrive.
+ * We don't have a complete packet yet. If we've already
+ * processed a packet, break out so we'll shift this packet
+ * to the start of the buffer. If we're already at the
+ * start, simply return and wait for more data to arrive.
*/
DEBUGMSGTL(("sess_read",
"pkt not complete (need %d got %d so far)\n",
pdulen, isp->packet_len));
+
+ if (pptr != isp->packet)
+ break; /* opaque freed for us outside of loop. */
+
if (opaque != NULL) {
SNMP_FREE(opaque);
}
Index: net-snmp.spec
===================================================================
RCS file: /cvs/dist/rpms/net-snmp/devel/net-snmp.spec,v
retrieving revision 1.55
retrieving revision 1.56
diff -u -r1.55 -r1.56
--- net-snmp.spec 29 Nov 2005 08:15:28 -0000 1.55
+++ net-snmp.spec 7 Dec 2005 08:47:57 -0000 1.56
@@ -3,7 +3,7 @@
Summary: A collection of SNMP protocol tools and libraries.
Name: net-snmp
Version: 5.2.2
-Release: 1
+Release: 2
License: BSDish
Group: System Environment/Daemons
URL: http://net-snmp.sourceforge.net/
@@ -27,6 +27,7 @@
#Patch10: net-snmp-5.1.1-ipAdEntIfIndex.patch
Patch12: net-snmp-5.1.2-dir-fix.patch
Patch19: net-snmp-5.2.1-file_offset.patch
+Patch20: net-snmp-5.2.2-tcp-partial-packet.patch
Prereq: /sbin/chkconfig
Obsoletes: ucd-snmp
@@ -126,6 +127,7 @@
%patch9 -b .64bit
%patch12 -p1 -b .dir-fix
%patch19 -p1 -b .file_offset
+%patch20 -p0 -b .tcp-packet
# Do this patch with a perl hack...
perl -pi -e "s|'\\\$install_libdir'|'%{_libdir}'|" ltmain.sh
@@ -308,6 +310,9 @@
%{_libdir}/*.a
%changelog
+* Wed Dec 07 2005 Radek Vokal <rvokal at redhat.com> - 5.2.2-2
+- fix read problem on stream sockets (net-snmp bz#1337534)
+
* Tue Nov 29 2005 Radek Vokal <rvokal at redhat.com> - 5.2.2-1
- upgrade to 5.2.2 final
More information about the fedora-cvs-commits
mailing list