From fc0e827f1a4e8effc91a9aadc66346fe5e5846a5 Mon Sep 17 00:00:00 2001 From: cognet Date: Mon, 21 May 2007 14:38:45 +0000 Subject: Force the alignment of the chars arrays, as they are casted later to structs. gcc 4.2 doesn't do it by default, and that results in unaligned access on arm. --- sbin/ping/ping.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sbin') diff --git a/sbin/ping/ping.c b/sbin/ping/ping.c index 90e2869..be5f66e 100644 --- a/sbin/ping/ping.c +++ b/sbin/ping/ping.c @@ -226,7 +226,7 @@ main(argc, argv) struct msghdr msg; struct sigaction si_sa; size_t sz; - u_char *datap, packet[IP_MAXPACKET]; + u_char *datap, packet[IP_MAXPACKET] __aligned(4); char *ep, *source, *target, *payload; struct hostent *hp; #ifdef IPSEC_POLICY_IPSEC -- cgit v1.1