Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mRemoteNG/PuTTYNG.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Tatham <anakin@pobox.com>2020-02-02 13:00:43 +0300
committerSimon Tatham <anakin@pobox.com>2020-02-02 13:02:10 +0300
commitfb5da46c4826f5bfbbe158c05b88de49e1c3b930 (patch)
tree4609b586a27e48f5a2354e1f1639614772fe4957 /cmdgen.c
parent9729aabd949af9b9971deb76ed67f472d67f5d92 (diff)
Make more file-scope variables static.
In the previous trawl of this, I didn't bother with the statics in main-program modules, on the grounds that my main aim was to avoid 'library' objects (shared between multiple programs) from polluting the global namespace. But I think it's worth being more strict after all, so this commit adds 'static' to a lot more file-scope variables that aren't needed outside their own module.
Diffstat (limited to 'cmdgen.c')
-rw-r--r--cmdgen.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/cmdgen.c b/cmdgen.c
index 8e2d07a5..a6dd1991 100644
--- a/cmdgen.c
+++ b/cmdgen.c
@@ -34,7 +34,7 @@
* I define another main() which calls the former repeatedly to
* run tests.
*/
-bool cgtest_verbose = false;
+static bool cgtest_verbose = false;
#define get_random_data get_random_data_diagnostic
char *get_random_data(int len, const char *device)
{
@@ -43,8 +43,8 @@ char *get_random_data(int len, const char *device)
return buf;
}
#define console_get_userpass_input console_get_userpass_input_diagnostic
-int nprompts, promptsgot;
-const char *prompts[3];
+static int nprompts, promptsgot;
+static const char *prompts[3];
int console_get_userpass_input(prompts_t *p)
{
size_t i;
@@ -1118,7 +1118,7 @@ int main(int argc, char **argv)
#include <stdarg.h>
-int passes, fails;
+static int passes, fails;
void setup_passphrases(char *first, ...)
{