[openswan/f17] ikeping strict aliasing issue leading to build failure,
avesh
avesh at fedoraproject.org
Fri Mar 23 19:13:36 UTC 2012
commit 16f31a12fd27deb41949010c50fcb2d173ea481b
Author: Avesh Agarwal <avagarwa at redhat.com>
Date: Fri Mar 23 15:13:34 2012 -0400
ikeping strict aliasing issue leading to build failure,
this fix is taken from upstream commit 094e119c
ikeping-strict-aliasing.patch | 32 ++++++++++++++++++++++++++++++++
openswan.spec | 8 +++++++-
2 files changed, 39 insertions(+), 1 deletions(-)
---
diff --git a/ikeping-strict-aliasing.patch b/ikeping-strict-aliasing.patch
new file mode 100644
index 0000000..79a22fe
--- /dev/null
+++ b/ikeping-strict-aliasing.patch
@@ -0,0 +1,32 @@
+diff -urNp openswan-2.6.37-patched/programs/ikeping/ikeping.c openswan-2.6.37-current/programs/ikeping/ikeping.c
+--- openswan-2.6.37-patched/programs/ikeping/ikeping.c 2011-10-28 17:11:53.000000000 -0400
++++ openswan-2.6.37-current/programs/ikeping/ikeping.c 2012-03-23 15:02:16.088291242 -0400
+@@ -194,7 +194,7 @@ receive_ping(int afamily, int s, int rep
+ unsigned int sendlen;
+ const char *xchg_name;
+ int xchg;
+- u_int32_t tmp_ic, tmp_rc;
++ u_int32_t tmp_ic[2], tmp_rc[2];
+
+ rport = 500;
+ xchg = 0;
+@@ -254,13 +254,13 @@ receive_ping(int afamily, int s, int rep
+ printf("received %d(%s) packet from %s/%d of len: %d\n",
+ ih.isa_xchg, xchg_name, buf, ntohs(rport), n);
+
+- memcpy(&tmp_ic, ih.isa_icookie, sizeof(u_int32_t));
+- memcpy(&tmp_rc, ih.isa_rcookie, sizeof(u_int32_t));
++ memcpy(&tmp_ic, ih.isa_icookie, 2 * sizeof(u_int32_t));
++ memcpy(&tmp_rc, ih.isa_rcookie, 2 * sizeof(u_int32_t));
+ printf("\trcookie=%08x_%08x icookie=%08x_%08x msgid=%08x\n",
+- tmp_ic,
+- *(u_int32_t *)(ih.isa_icookie+4),
+- tmp_rc,
+- *(u_int32_t *)(ih.isa_rcookie+4),
++ tmp_ic[0],
++ tmp_ic[1],
++ tmp_rc[0],
++ tmp_rc[1],
+ ih.isa_msgid);
+ printf("\tnp=%03d version=%d.%d xchg=%s(%d)\n",
+ ih.isa_np,
diff --git a/openswan.spec b/openswan.spec
index 401c247..db36faf 100644
--- a/openswan.spec
+++ b/openswan.spec
@@ -10,7 +10,7 @@ Summary: IPSEC implementation with IKEv1 and IKEv2 keying protocols
Name: openswan
Version: 2.6.37
-Release: 2%{?dist}
+Release: 3%{?dist}
License: GPLv2+
Url: http://www.openswan.org/
Source: openswan-%{version}.tar.gz
@@ -21,6 +21,7 @@ Source3: README.x509
Patch1: openswan-2.6-relpath.patch
Patch2: openswan-ipsec-help-524146-509318.patch
Patch3: openswan-cisco-issues.patch
+Patch4: ikeping-strict-aliasing.patch
Group: System Environment/Daemons
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
@@ -85,6 +86,7 @@ install -m 644 %{SOURCE3} docs/README.x509
%patch1 -p1 -b .relpath
%patch2 -p1
%patch3 -p1
+%patch4 -p1
%build
@@ -209,6 +211,10 @@ fi
chkconfig --add ipsec || :
%changelog
+* Fri Mar 23 2012 Avesh Agarwal <avagarwa at redhat.com> - 2.6.37-3
+- ikeping strict aliasing issue leading to build failure,
+ this fix is taken from upstream commit 094e119c
+
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng at lists.fedoraproject.org> - 2.6.37-2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
More information about the scm-commits
mailing list