summaryrefslogtreecommitdiffstats
path: root/usr.bin/enigma/enigma.c
diff options
context:
space:
mode:
authored <ed@FreeBSD.org>2011-11-06 18:49:23 +0000
committered <ed@FreeBSD.org>2011-11-06 18:49:23 +0000
commitb333c8830884a56cbd10db2d70a22d85472f5572 (patch)
tree30ed72bc13f2e3651238e9643065e3cee9bbac2d /usr.bin/enigma/enigma.c
parenta7c3f252fc7d53e70f895dfcdff15b1d396a90d5 (diff)
downloadFreeBSD-src-b333c8830884a56cbd10db2d70a22d85472f5572.zip
FreeBSD-src-b333c8830884a56cbd10db2d70a22d85472f5572.tar.gz
Mark global functions and/or variables in enigma(1) static where possible.
This allows compilers and static analyzers to more thorough analysis.
Diffstat (limited to 'usr.bin/enigma/enigma.c')
-rw-r--r--usr.bin/enigma/enigma.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/usr.bin/enigma/enigma.c b/usr.bin/enigma/enigma.c
index 68fd29d..49cb006 100644
--- a/usr.bin/enigma/enigma.c
+++ b/usr.bin/enigma/enigma.c
@@ -25,16 +25,16 @@ __FBSDID("$FreeBSD$");
#define ECHO 010
#define ROTORSZ 256
#define MASK 0377
-char t1[ROTORSZ];
-char t2[ROTORSZ];
-char t3[ROTORSZ];
-char deck[ROTORSZ];
-char buf[13];
+static char t1[ROTORSZ];
+static char t2[ROTORSZ];
+static char t3[ROTORSZ];
+static char deck[ROTORSZ];
+static char buf[13];
-void shuffle(char *);
-void setup(char *);
+static void shuffle(char *);
+static void setup(char *);
-void
+static void
setup(char *pw)
{
int ic, i, k, temp;
@@ -128,7 +128,7 @@ main(int argc, char *argv[])
return 0;
}
-void
+static void
shuffle(char deckary[])
{
int i, ic, k, temp;
OpenPOWER on IntegriCloud