This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: gcc stack-smashing protector (for gcc-3.2.1)
- From: "Joseph S. Myers" <jsm28 at cam dot ac dot uk>
- To: Fergus Henderson <fjh at cs dot mu dot OZ dot AU>
- Cc: Neil Booth <neil at daikokuya dot co dot uk>, Hiroaki Etoh <etoh at trl dot ibm dot com>, <gcc-patches at gcc dot gnu dot org>
- Date: Fri, 10 Jan 2003 10:27:50 +0000 (GMT)
- Subject: Re: gcc stack-smashing protector (for gcc-3.2.1)
On Fri, 10 Jan 2003, Fergus Henderson wrote:
> A simple way to do that would be to add a rule to the Makefile that
> checks for such things, e.g. using grep.
> For example:
>
> check: check_sources
>
> .PHONY: check_sources
> check_sources:
> if fgrep -n "`cat POISONED_WORDS`" *.c *.h 1>&2; then
> echo "The lines above contain poisoned words" 1>&2
> exit 1
> fi
Some words it's useful to grep for also have legitimate uses, e.g.
grepping for "675" finds notices with the old FSF address, but also some
long tables of numbers.
--
Joseph S. Myers
jsm28@cam.ac.uk