]> git.pond.sub.org Git - empserver/blobdiff - src/lib/common/nsc.c
New macro ARRAY_SIZE()
[empserver] / src / lib / common / nsc.c
index 6b4c6b079926ba6a4285394fc2a1a5f1787183df..d66493e64518f82ff000a0f2a3241341b9072a3e 100644 (file)
@@ -1,6 +1,6 @@
 /*
  *  Empire - A multi-player, client/server Internet based war game.
- *  Copyright (C) 1986-2016, Dave Pare, Jeff Bailey, Thomas Ruschak,
+ *  Copyright (C) 1986-2020, Dave Pare, Jeff Bailey, Thomas Ruschak,
  *                Ken Stevens, Steve McClure, Markus Armbruster
  *
  *  Empire is free software: you can redistribute it and/or modify
@@ -27,7 +27,7 @@
  *  nsc.c: Empire selection global structures
  *
  *  Known contributors to this file:
- *     Markus Armbruster, 2004-2016
+ *     Markus Armbruster, 2004-2020
  */
 
 /*
@@ -640,7 +640,7 @@ struct castr cou_ca[] = {
 #undef CURSTR
 };
 
-struct castr nat_ca[sizeof(cou_ca) / sizeof(*cou_ca)];
+struct castr nat_ca[ARRAY_SIZE(cou_ca)];
 /* initialized by nsc_init() */
 
 struct castr relat_ca[] = {
@@ -752,7 +752,7 @@ struct castr empfile_ca[] = {
 struct castr symbol_ca[] = {
 #define CURSTR struct symbol
     /*
-     * value is is const because it has to match what is compiled into
+     * value is const because it has to match what is compiled into
      * the server.  name is const because clients key on it.
      */
     {"value", fldoff(value), NSC_INT, 0, NULL, EF_BAD, 0, CA_DUMP_CONST},