rpms/libnet/EL-5 libnet-1.1.2.1-odd_chksum.patch, NONE, 1.1 libnet.spec, 1.8, 1.9
Patrice Dumas (pertusus)
fedora-extras-commits at redhat.com
Tue Mar 27 21:48:50 UTC 2007
Author: pertusus
Update of /cvs/extras/rpms/libnet/EL-5
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv2917
Modified Files:
libnet.spec
Added Files:
libnet-1.1.2.1-odd_chksum.patch
Log Message:
* Fri Jan 12 2007 Patrice Dumas <pertusus at free.fr> 1.1.2.1-10
- add debian patch to correct bad checksums
libnet-1.1.2.1-odd_chksum.patch:
--- NEW FILE libnet-1.1.2.1-odd_chksum.patch ---
--- libnet-1.1.2.1.orig/src/libnet_checksum.c
+++ libnet-1.1.2.1/src/libnet_checksum.c
@@ -42,8 +42,10 @@
libnet_in_cksum(u_int16_t *addr, int len)
{
int sum;
+ u_int16_t last_byte;
sum = 0;
+ last_byte = 0;
while (len > 1)
{
@@ -52,7 +54,8 @@
}
if (len == 1)
{
- sum += *(u_int16_t *)addr;
+ *(u_int8_t*)&last_byte = *(u_int8_t*)addr;
+ sum += last_byte;
}
return (sum);
Index: libnet.spec
===================================================================
RCS file: /cvs/extras/rpms/libnet/EL-5/libnet.spec,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -r1.8 -r1.9
--- libnet.spec 29 Aug 2006 11:09:47 -0000 1.8
+++ libnet.spec 27 Mar 2007 21:48:17 -0000 1.9
@@ -1,11 +1,14 @@
Summary: C library for portable packet creation and injection
Name: libnet
Version: 1.1.2.1
-Release: 9%{?dist}
+Release: 10%{?dist}
License: BSD
Group: System Environment/Libraries
URL: http://www.packetfactory.net/libnet/
Source0: http://www.packetfactory.net/libnet/dist/libnet-%{version}.tar.gz
+# excerpted from debian patcheset
+Patch0: libnet-1.1.2.1-odd_chksum.patch
+
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
%description
@@ -34,6 +37,7 @@
%prep
%setup -q -n libnet
+%patch0 -p1 -b odd_chksum
sed -i -e 's/\r$//' doc/CHANGELOG doc/CONTRIB
find . -depth -type d -name CVS -exec rm -rf {} ';'
rm -rf sample/win32
@@ -71,34 +75,37 @@
%{_mandir}/man3/libnet*
%changelog
-* Tue Aug 29 2006 Patrice Dumas <dumas at centre-cired.fr> - 1.1.2.1-9
+* Fri Jan 12 2007 Patrice Dumas <pertusus at free.fr> 1.1.2.1-10
+- add debian patch to correct bad checksums
+
+* Tue Aug 29 2006 Patrice Dumas <pertusus at free.fr> 1.1.2.1-9
- rebuild for FC6
-* Fri Feb 17 2006 Patrice Dumas <dumas at centre-cired.fr> - 1.1.2.1-8
+* Fri Feb 17 2006 Patrice Dumas <pertusus at free.fr> 1.1.2.1-8
- rebuild for fc5
-* Thu Dec 22 2005 Patrice Dumas <dumas at centre-cired.fr> - 1.1.2.1-7
+* Thu Dec 22 2005 Patrice Dumas <pertusus at free.fr> 1.1.2.1-7
- rebuild
-* Mon Sep 12 2005 Patrice Dumas <dumas at centre-cired.fr> 1.1.2.1-6
+* Mon Sep 12 2005 Patrice Dumas <pertusus at free.fr> 1.1.2.1-6
- bump release and add dist tag
* Tue Aug 30 2005 Paul Howarth <paul at city-fan.org> 1.1.2.1-5
- spec file cleanup
-* Fri Aug 26 2005 Patrice Dumas <dumas at centre-cired.fr> 1.1.2.1-4
+* Fri Aug 26 2005 Patrice Dumas <pertusus at free.fr> 1.1.2.1-4
- use pushd and popd (from Oliver Falk)
-* Mon Aug 22 2005 Patrice Dumas <dumas at centre-cired.fr> 1.1.2.1-3
+* Mon Aug 22 2005 Patrice Dumas <pertusus at free.fr> 1.1.2.1-3
- Correct dos end of lines
- add in devel: Provides: %%{name} = %%{version}-%%{release}
-* Fri Aug 12 2005 Patrice Dumas <dumas at centre-cired.fr> 1.1.2.1-2
+* Fri Aug 12 2005 Patrice Dumas <pertusus at free.fr> 1.1.2.1-2
- put everything in a devel subpackage
- add smpflags
- clean in sample
-* Fri Aug 12 2005 Patrice Dumas <dumas at centre-cired.fr> 1.1.2.1-1
+* Fri Aug 12 2005 Patrice Dumas <pertusus at free.fr> 1.1.2.1-1
- rebuild changing only name
* Wed Jun 02 2004 Marcin Garski <garski at poczta.onet.pl> 1.1.2.1-2.fc2
More information about the fedora-extras-commits
mailing list