diff options
author | pfg <pfg@FreeBSD.org> | 2015-07-30 14:31:09 +0000 |
---|---|---|
committer | pfg <pfg@FreeBSD.org> | 2015-07-30 14:31:09 +0000 |
commit | b1425be92a300456f5b779869a0535944ca59fce (patch) | |
tree | 562aa7ccc8fd38b31da1ac6f125a04eed1d1f0f0 /contrib/gcc/c-cppbuiltin.c | |
parent | 52a7aa675b08cdb66f31e18638142de62b71c046 (diff) | |
download | FreeBSD-src-b1425be92a300456f5b779869a0535944ca59fce.zip FreeBSD-src-b1425be92a300456f5b779869a0535944ca59fce.tar.gz |
GCC: Add a new option "-fstack-protector-strong"
This includes additional functions to be protected: those that
have local array definitions, or have references to local frame
addresses. This is a new option in GCC-4.9 that was relicensed
by Han Shen from Google under GPLv2 for OpenBSD.
Obtained from: OpenBSD (2014-01-14)
MFC after: 2 weeks
Diffstat (limited to 'contrib/gcc/c-cppbuiltin.c')
-rw-r--r-- | contrib/gcc/c-cppbuiltin.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/contrib/gcc/c-cppbuiltin.c b/contrib/gcc/c-cppbuiltin.c index 6b65cdf..511104f 100644 --- a/contrib/gcc/c-cppbuiltin.c +++ b/contrib/gcc/c-cppbuiltin.c @@ -553,7 +553,9 @@ c_cpp_builtins (cpp_reader *pfile) /* Make the choice of the stack protector runtime visible to source code. The macro names and values here were chosen for compatibility with an earlier implementation, i.e. ProPolice. */ - if (flag_stack_protect == 2) + if (flag_stack_protect == 3) + cpp_define (pfile, "__SSP_STRONG__=3"); + else if (flag_stack_protect == 2) cpp_define (pfile, "__SSP_ALL__=2"); else if (flag_stack_protect == 1) cpp_define (pfile, "__SSP__=1"); |