diff options
author | ed <ed@FreeBSD.org> | 2011-11-06 18:49:48 +0000 |
---|---|---|
committer | ed <ed@FreeBSD.org> | 2011-11-06 18:49:48 +0000 |
commit | bfc6ddd863312885df4f946aef871e51e4315ee2 (patch) | |
tree | d10963e5d3bcc4f426882f6c0f8bceab9815125d /usr.bin | |
parent | fb0088d7d03a3ea8e345fa7da1cdbf560f49d313 (diff) | |
download | FreeBSD-src-bfc6ddd863312885df4f946aef871e51e4315ee2.zip FreeBSD-src-bfc6ddd863312885df4f946aef871e51e4315ee2.tar.gz |
Mark global functions and/or variables in m4(1) static where possible.
This allows compilers and static analyzers to more thorough analysis.
Diffstat (limited to 'usr.bin')
-rw-r--r-- | usr.bin/m4/gnum4.c | 2 | ||||
-rw-r--r-- | usr.bin/m4/main.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/m4/gnum4.c b/usr.bin/m4/gnum4.c index edfe296..fce443c 100644 --- a/usr.bin/m4/gnum4.c +++ b/usr.bin/m4/gnum4.c @@ -60,7 +60,7 @@ int mimic_gnu = 0; * Then M4PATH env variable */ -struct path_entry { +static struct path_entry { char *name; struct path_entry *next; } *first, *last; diff --git a/usr.bin/m4/main.c b/usr.bin/m4/main.c index 0e60fce..f16b4df 100644 --- a/usr.bin/m4/main.c +++ b/usr.bin/m4/main.c @@ -99,7 +99,7 @@ char scommt[MAXCCHARS+1] = {SCOMMT}; /* start character for comment */ char ecommt[MAXCCHARS+1] = {ECOMMT}; /* end character for comment */ int synccpp; /* Line synchronisation for C preprocessor */ -struct keyblk keywrds[] = { /* m4 keywords to be installed */ +static const struct keyblk keywrds[] = { /* m4 keywords to be installed */ { "include", INCLTYPE }, { "sinclude", SINCTYPE }, { "define", DEFITYPE }, |