bug-binutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug ld/12982] New: BFD linker LTO plugin makes stack executable by defa


From: hjl.tools at gmail dot com
Subject: [Bug ld/12982] New: BFD linker LTO plugin makes stack executable by default
Date: Mon, 11 Jul 2011 18:35:29 +0000

http://sourceware.org/bugzilla/show_bug.cgi?id=12982

           Summary: BFD linker LTO plugin makes stack executable by
                    default
           Product: binutils
           Version: 2.22 (HEAD)
               URL: http://gcc.gnu.org/bugzilla/show_bug.cgi?id=49703
            Status: NEW
          Severity: normal
          Priority: P2
         Component: ld
        AssignedTo: address@hidden
        ReportedBy: address@hidden


$ cat xx.c
#include <stdio.h>
int main(int argc, char **argv) {
        printf("Hallo\n");
        return 0;
}
$ gcc -O2 -o xx xx.c
$ readelf -a xx|grep STACK
  GNU_STACK      0x000000 0x00000000 0x00000000 0x00000 0x00000 RW  0x4
$ gcc -flto -O2 -o xx xx.c
$ readelf -a xx|grep STACK
  GNU_STACK      0x000000 0x00000000 0x00000000 0x00000 0x00000 RWE 0x4

-flto should not create executable stacks.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]