The code in attachments fails on buffer overflow when compiled and run on ppc (64bit kernel, 32bit userspace), but runs clean on x86_64 Version-Release number of selected component (if applicable): gcc-4.4.0-0.21.ppc Steps to Reproduce: 1. gcc -O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -D_GNU_SOURCE -D_REENTRANT test.c 2. ./a.put Actual results: *** buffer overflow detected ***: ./a.out terminated ======= Backtrace: ========= /lib/libc.so.6(__fortify_fail+0x6c)[0xff5c26c] /lib/libc.so.6[0xff59718] /lib/libc.so.6(__strncpy_chk+0x1b4)[0xff586f4] ./a.out[0x10000500] /lib/libc.so.6[0xfe5ac64] /lib/libc.so.6[0xfe5ae20] ======= Memory map: ======== 00100000-00103000 r-xp 00100000 00:00 0 [vdso] 0fe3c000-0ffd5000 r-xp 00000000 fd:00 3212337 /lib/libc-2.9.90.so 0ffd5000-0ffe8000 ---p 00199000 fd:00 3212337 /lib/libc-2.9.90.so 0ffe8000-0ffec000 r--p 0019c000 fd:00 3212337 /lib/libc-2.9.90.so 0ffec000-0ffed000 rw-p 001a0000 fd:00 3212337 /lib/libc-2.9.90.so 0ffed000-0fff0000 rw-p 0ffed000 00:00 0 10000000-10001000 r-xp 00000000 fd:00 294938 /root/dhorak/test/a.out 10010000-10011000 rw-p 00000000 fd:00 294938 /root/dhorak/test/a.out f7fbc000-f7fbe000 rw-p f7fbc000 00:00 0 f7fbe000-f7fe2000 r-xp 00000000 fd:00 3212322 /lib/ld-2.9.90.so f7ffd000-f7ffe000 r--p 0002f000 fd:00 3212322 /lib/ld-2.9.90.so f7ffe000-f7fff000 rw-p 00030000 fd:00 3212322 /lib/ld-2.9.90.so ffd43000-ffd58000 rw-p ffffffeb000 00:00 0 [stack] Neúspěšně ukončen (SIGABRT) This is a test case for buffer overflow aborts that can be seen at ppc = https://koji.fedoraproject.org/koji/getfile?taskID=1177236&name=build.log ppc64 = https://koji.fedoraproject.org/koji/getfile?taskID=1190281&name=build.log (scratch builds)
Created attachment 333491 [details] test.c
Created attachment 333492 [details] test.h
removing any (?, but I have tried to remove a lot of them, one at time) of the struct members makes the code run without an abort
Tracking this upstream.
Should be fixed in gcc-4.4.0-0.22.
(In reply to comment #5) > Should be fixed in gcc-4.4.0-0.22. confirmed