PR other/88007
commitf6742350318da0dd5403bed055bd6d17b365aaf5
authorjakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4>
Wed, 14 Nov 2018 12:38:20 +0000 (14 12:38 +0000)
committerjakub <jakub@138bc75d-0d04-0410-961f-82ee72b054a4>
Wed, 14 Nov 2018 12:38:20 +0000 (14 12:38 +0000)
treecf23cca3962027a5a39d599d84a2973d7a5cc7b0
parent8d5aee98ab10d847bc9b6354cd64f4b0f580c85d
PR other/88007
* c-common.c (parse_optimize_options): Allocate option string from
opts_obstack rather than as GC memory.  Move the allocation after
warning for invalid option.

* gcc.dg/pr88007.c: New test.

git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@266141 138bc75d-0d04-0410-961f-82ee72b054a4
gcc/c-family/ChangeLog
gcc/c-family/c-common.c
gcc/testsuite/ChangeLog
gcc/testsuite/gcc.dg/pr88007.c [new file with mode: 0644]