]> git.pond.sub.org Git - empserver/commitdiff
(NS_ALL) [_WIN32]: Change NS_EVERYTHING back to NS_ALL, #undef NS_ALL to prevent...
authorRon Koenderink <rkoenderink@yahoo.ca>
Tue, 8 Mar 2005 00:04:43 +0000 (00:04 +0000)
committerRon Koenderink <rkoenderink@yahoo.ca>
Tue, 8 Mar 2005 00:04:43 +0000 (00:04 +0000)
include/nsc.h
src/lib/commands/tend.c
src/lib/empthread/ntthread.c
src/lib/gen/io.c
src/lib/player/accept.c
src/lib/subs/nxtitem.c
src/lib/subs/sarg.c
src/lib/subs/snxtitem.c
src/lib/subs/snxtsct.c
src/lib/update/nxtitemp.c
src/server/main.c

index 801416beca3f04060c4eb0a611733886ce1dc97e..e48c3323ec7fdcc7b9ad54cd9272b7b58137fa67 100644 (file)
@@ -129,7 +129,7 @@ typedef enum {
     NS_LIST,                   /* list of IDs */
     NS_DIST,                   /* circular area */
     NS_AREA,                   /* rectangular area */
-    NS_EVERYTHING,             /* everything */
+    NS_ALL,            /* everything */
     NS_XY,                     /* one sector area */
     NS_GROUP                   /* group, i.e. fleet, wing, army */
 } ns_seltype;
index 0d2c0b7530dbf0418b875c9f8d576a30e2e1cac0..c26387e3049f0548158efd8365f1e01ff4cdfec7 100644 (file)
@@ -232,8 +232,8 @@ tend_nxtitem(struct nstr_item *np, void *ptr)
        case NS_LIST:
            /* The change is to take the player->owner check out here */
            break;
-       case NS_EVERYTHING:
-           /* XXX maybe combine NS_LIST and NS_EVERYTHING later */
+       case NS_ALL:
+           /* XXX maybe combine NS_LIST and NS_ALL later */
            break;
        case NS_DIST:
            if (!xyinrange(gp->x, gp->y, &np->range)) {
index f3c99762661f14c868328aba4f0f6e858358f559..18026a4e8b85f88b33888d18e2c2b0bf24f5132c 100644 (file)
@@ -56,6 +56,7 @@
 
 #if defined(_WIN32) && defined(_EMPTH_WIN32)
 #include <winsock2.h>
+#undef NS_ALL
 #include <windows.h>
 #include <process.h>
 
index fe97149e131535d90cba2131ba4a0f3b961f18f4..271a2cd0397a4ac2e260b383dc251c11c964335f 100644 (file)
@@ -53,6 +53,7 @@
 
 #if defined(_WIN32)
 #include <winsock2.h>
+#undef NS_ALL
 #endif
 
 #include "misc.h"
index 2581337a4a862b7b90e9c3c725eda55b39e75585..eb160ff82f53e0f850c105cef73c7e0abf3056bd 100644 (file)
  *     Dave Pare, 1994
  */
 
+#if defined(_WIN32)
+#include <winsock2.h>
+#undef NS_ALL
+#endif
+
 #include "prototypes.h"
 #include "misc.h"
 #include "proto.h"
@@ -51,8 +56,6 @@
 #include <netinet/in.h>
 #include <sys/ioctl.h>
 #include <unistd.h>
-#else
-#include <winsock2.h>
 #endif
 #include <signal.h>
 #include <errno.h>
index c702c38d5f27368ec7cd97f98526ed32effc011b..6a719812c7646802a5b878643737dfc336bad3bb 100644 (file)
@@ -72,8 +72,8 @@ nxtitem(struct nstr_item *np, void *ptr)
            if ((np->flags & EFF_OWNER) && !player->owner)
                selected = 0;
            break;
-       case NS_EVERYTHING:
-           /* XXX maybe combine NS_LIST and NS_EVERYTHING later */
+       case NS_ALL:
+           /* XXX maybe combine NS_LIST and NS_ALL later */
            break;
        case NS_DIST:
            if (!xyinrange(gp->x, gp->y, &np->range)) {
index a0bf2b1e35173383ad1aaeb666e36cc8e76c1d4c..6b87aa5786d8ae44fb727046b4b42a1e531105f5 100644 (file)
@@ -48,7 +48,7 @@
  *  #1, lx:ly,hx:hy --> NS_AREA
  *  @x,y:dist  --> NS_DIST
  *  %d or %d/%d/%d --> NS_LIST
- *  * --> NS_EVERYTHING
+ *  * --> NS_ALL
  *
  * or 0 for none of the above.
  */
@@ -61,7 +61,7 @@ sarg_type(char *str)
     if (c == '@')
        return NS_DIST;
     if (c == '*')
-       return NS_EVERYTHING;
+       return NS_ALL;
     if (c == '#' || strchr(str, ',') != 0)
        return NS_AREA;
     if (isdigit(c))
index e6b00cee73f05bb04203a55298761fbf4fcda7e4..1f1896a297d2c43d03efcb81d3f48fd38cb21742 100644 (file)
@@ -40,7 +40,7 @@
 
 /*
  * setup the nstr structure for sector selection.
- * can select on NS_EVERYTHING, NS_AREA, NS_DIST, and NS_LIST.
+ * can select on NS_ALL, NS_AREA, NS_DIST, and NS_LIST.
  * iterate thru the "condarg" string looking
  * for arguments to compile into the nstr.
  */
@@ -89,7 +89,7 @@ snxtitem(struct nstr_item *np, int type, s_char *str)
            return 0;
        snxtitem_dist(np, type, cx, cy, dist);
        break;
-    case NS_EVERYTHING:
+    case NS_ALL:
        snxtitem_all(np, type);
        break;
     case NS_LIST:
@@ -184,7 +184,7 @@ snxtitem_all(struct nstr_item *np, int type)
 {
     memset(np, 0, sizeof(*np));
     np->cur = -1;
-    np->sel = NS_EVERYTHING;
+    np->sel = NS_ALL;
     np->type = type;
     np->index = -1;
     np->read = ef_read;
index a737d848342282d181868d6adccdf7799fc60850..5a03e9c66b4920a074b4955999783c6634a05689 100644 (file)
@@ -41,7 +41,7 @@
 
 /*
  * setup the nstr_sect structure for sector selection.
- * can select on either NS_EVERYTHING, NS_AREA, or NS_RANGE
+ * can select on either NS_ALL, NS_AREA, or NS_RANGE
  * iterate thru the "condarg" string looking
  * for arguments to compile into the nstr.
  */
@@ -74,7 +74,7 @@ snxtsct(struct nstr_sect *np, s_char *str)
            return 0;
        snxtsct_dist(np, cx, cy, dist);
        break;
-    case NS_EVERYTHING:
+    case NS_ALL:
        /* fake "all" by doing a world-sized area query */
        snxtsct_area(np, &wr);
        break;
index 0b7015a96cdf6de58742e42edad3b9119cc764bf..b5ccbeddb63a29f1f108cd82d098f69e21e331fe 100644 (file)
@@ -74,8 +74,8 @@ nxtitemp(struct nstr_item *np, int owner)
            if ((np->flags & EFF_OWNER) && !owner)
                selected = 0;
            break;
-       case NS_EVERYTHING:
-           /* XXX maybe combine NS_LIST and NS_EVERYTHING later */
+       case NS_ALL:
+           /* XXX maybe combine NS_LIST and NS_ALL later */
            break;
        case NS_DIST:
            if (!xyinrange(gp->x, gp->y, &np->range)) {
index 305fd507dc78ad7c2bfe796feb1356ab8a049e2f..1dc962f99b3523904440717e002cbb28e4e2ece4 100644 (file)
@@ -47,6 +47,7 @@
 
 #if defined(_WIN32)
 #include <winsock2.h>
+#undef NS_ALL
 #include <process.h>
 #include "../lib/gen/getopt.h"
 #include "service.h"