]> git.pond.sub.org Git - empserver/commitdiff
(dirchar, neighsects, login_coms, lookup_list, g_distptrs, level_easy)
authorMarkus Armbruster <armbru@pond.sub.org>
Thu, 23 Mar 2006 20:32:29 +0000 (20:32 +0000)
committerMarkus Armbruster <armbru@pond.sub.org>
Thu, 23 Mar 2006 20:32:29 +0000 (20:32 +0000)
(level_log, levelnames): Internal linkage.

src/lib/common/bestpath.c
src/lib/common/path.c
src/lib/player/login.c
src/lib/subs/show.c
src/lib/update/finish.c
src/lib/update/nat.c
src/lib/update/produce.c

index 156336936d8cd1891f2cabf5ea1c3b69ef64155d..4f2c4fb780e1ac9bafc1b7003812f9c129a96a4a 100644 (file)
@@ -105,7 +105,7 @@ static int owned_and_navigable(s_char *, int, int, s_char *, int);
 ** ________________________________________________________________
 */
 
-s_char *dirchar = "juygbn";
+static char *dirchar = "juygbn";
 int dx[6] = { 2, 1, -1, -2, -1, 1 };
 int dy[6] = { 0, -1, -1, 0, 1, 1 };
 
index 351759e070a1923dc3469354089c5d89ac6447dd..3acf7222fbab255320feb3b992c32dd62836919e 100644 (file)
@@ -72,7 +72,7 @@ static int bp_coord_hash(struct as_coord c);
 
 /* We use this for caching neighbors.  It never changes except
  * at reboot time (maybe) so we never need to free it */
-struct sctstr **neighsects = (struct sctstr **)0;
+static struct sctstr **neighsects;
 
 static s_char *
 bp_init(void)
index e829206e708e9e3b384fccca2555f837512038e1..dd7d5a38b0bf5c7a1e7dc5c64c94e3ef0b9dff7e 100644 (file)
@@ -359,7 +359,7 @@ quit_cmd(void)
     return RET_OK;
 }
 
-struct cmndstr login_coms[] = {
+static struct cmndstr login_coms[] = {
     {"client client-id...", 0, client_cmd, 0, 0},
     {"coun country", 0, coun_cmd, 0, 0},
     {"kill", 0, kill_cmd, 0, 0},
index d25989fb0c047f328c462d36c4b7136246fafe45..5291a0b66eb1250a0a7c1e8648314b61b104f7f4 100644 (file)
@@ -59,8 +59,13 @@ struct look_list {
        struct mchrstr *mp;
     } l_u;
     int tech;
-} lookup_list[200];            /* Change this if there are ever more than 200 planes, ships
-                                  or land units. */
+};
+
+/*
+ * Change this if there are ever more than 200 ships, plane or land
+ * unit types.
+ */
+static struct look_list lookup_list[200];
 static int lookup_list_cnt = 0;
 
 static void
index 0ba35506f4e3bc375e6ad9a3f82bab12bdb71310..799f795e6196ad658a4ff85adafd9edd4d9e98c1 100644 (file)
@@ -56,7 +56,7 @@ struct distinfo {
 /* This is our global buffer of distribution pointers.  Note that
  * We only malloc this once, and never again (until reboot time
  * of course :) ) We do clear it each and every time. */
-struct distinfo *g_distptrs = (struct distinfo *)0;
+static struct distinfo *g_distptrs;
 
 /* Note that even though we malloc and save the path, it is never
  * used.  Thus, this option.  If you want to malloc and save every
index 12d61325507abfe6d1d703b7f4e4a5951f632011..746a43f61a4c3cb87c1b2fc94720e9a9f47cf3b2 100644 (file)
@@ -72,8 +72,8 @@ static void share_incr(double *, double *);
  * They are changed later in the limit_level routine.
  */
                        /*tech   res   edu   hap */
-float level_easy[4] = { 0.75, 0.75, 5.00, 5.00 };
-float level_log[4] = { 1.75, 2.00, 4.00, 6.00 };
+static float level_easy[4] = { 0.75, 0.75, 5.00, 5.00 };
+static float level_log[4] = { 1.75, 2.00, 4.00, 6.00 };
 
 float levels[MAXNOC][4];
 
index bb53300377c024014a9ba93db2f2d11ae92aa907..f0bb792ad710bdc3398a663256bcfd7f9e5fd896 100644 (file)
@@ -49,8 +49,9 @@
 static void materials_charge(struct pchrstr *, short *, int);
 static int materials_cost(struct pchrstr *, short *, int *);
 
-s_char *levelnames[] =
-    { "Technology", "Research", "Education", "Happiness" };
+static char *levelnames[] = {
+    "Technology", "Research", "Education", "Happiness"
+};
 
 int
 produce(struct natstr *np, struct sctstr *sp, short *vec, int work,