From 98a4c7cf3d799ab953cb77e8b34597c73e3e7335 Mon Sep 17 00:00:00 2001 From: Denys Vlasenko Date: Thu, 4 Feb 2010 15:00:15 +0100 Subject: *: suppress ~60% of "aliased warnings" on gcc-4.4.1 Signed-off-by: Denys Vlasenko --- procps/ps.c | 2 +- procps/top.c | 4 +--- 2 files changed, 2 insertions(+), 4 deletions(-) (limited to 'procps') diff --git a/procps/ps.c b/procps/ps.c index 0b674ff..91ebd68 100644 --- a/procps/ps.c +++ b/procps/ps.c @@ -49,7 +49,7 @@ struct globals { unsigned long long seconds_since_boot; #endif char default_o[sizeof(DEFAULT_O_STR)]; -}; +} FIX_ALIASING; #define G (*(struct globals*)&bb_common_bufsiz1) #define out (G.out ) #define out_cnt (G.out_cnt ) diff --git a/procps/top.c b/procps/top.c index f514df7..d76d9af 100644 --- a/procps/top.c +++ b/procps/top.c @@ -100,10 +100,8 @@ struct globals { int num_cpus; #endif char line_buf[80]; -}; - +}; //FIX_ALIASING; - large code growth enum { LINE_BUF_SIZE = COMMON_BUFSIZE - offsetof(struct globals, line_buf) }; - #define G (*(struct globals*)&bb_common_bufsiz1) #define INIT_G() do { \ struct G_sizecheck { \ -- cgit v1.1