summaryrefslogtreecommitdiff
path: root/c++tools
diff options
context:
space:
mode:
authorNathan Sidwell <nathan@acm.org>2021-02-25 08:30:17 -0800
committerNathan Sidwell <nathan@acm.org>2021-02-25 08:58:26 -0800
commit9f08c08531b61b68a41c9c5403ec0cc288ae3aba (patch)
treea5918bb76626a060c98cedc89823c3e3a858e8e3 /c++tools
parenta47cec4ca7302e65f63490ad7f251c5a469bc0e0 (diff)
downloadgcc-9f08c08531b61b68a41c9c5403ec0cc288ae3aba.tar.gz
c++tools: Make NETWORKING define check consistent [PR 98318]
PR98318 also pointed out that the NETWORKING #define was being checked with both #if and #ifdef. Let's consistently use one form. c++tools/ * server.cc: Use #if NETWORKING not #ifdef, to be consistent with elsewhere.
Diffstat (limited to 'c++tools')
-rw-r--r--c++tools/server.cc14
1 files changed, 7 insertions, 7 deletions
diff --git a/c++tools/server.cc b/c++tools/server.cc
index 8514ef6293b..21c7d468aa0 100644
--- a/c++tools/server.cc
+++ b/c++tools/server.cc
@@ -63,7 +63,7 @@ along with GCC; see the file COPYING3. If not see
#include <getopt.h>
// Select or epoll
-#ifdef NETWORKING
+#if NETWORKING
#ifdef HAVE_EPOLL
/* epoll_create, epoll_ctl, epoll_pwait */
#include <sys/epoll.h>
@@ -91,7 +91,7 @@ along with GCC; see the file COPYING3. If not see
#define DIR_SEPARATOR '/'
#endif
-#ifdef NETWORKING
+#if NETWORKING
struct netmask {
in6_addr addr;
unsigned bits;
@@ -161,7 +161,7 @@ static bool flag_xlate = false;
/* Root binary directory. */
static const char *flag_root = "gcm.cache";
-#ifdef NETWORKING
+#if NETWORKING
static netmask_set_t netmask_set;
static netmask_vec_t accept_addrs;
@@ -233,7 +233,7 @@ error (const char *msg, ...)
exit (1);
}
-#ifdef NETWORKING
+#if NETWORKING
/* Progress messages to the user. */
static bool ATTRIBUTE_PRINTF_1 ATTRIBUTE_COLD
noisy (const char *fmt, ...)
@@ -414,7 +414,7 @@ process_args (int argc, char **argv)
return optind;
}
-#ifdef NETWORKING
+#if NETWORKING
/* Manipulate the EPOLL state, or do nothing, if there is epoll. */
@@ -871,7 +871,7 @@ main (int argc, char *argv[])
/* Ignore sigpipe, so read/write get an error. */
signal (SIGPIPE, SIG_IGN);
#endif
-#ifdef NETWORKING
+#if NETWORKING
#ifdef SIGINT
signal (SIGINT, kill_signal);
#endif
@@ -935,7 +935,7 @@ main (int argc, char *argv[])
}
#endif
-#ifdef NETWORKING
+#if NETWORKING
if (sock_fd >= 0)
{
server (name[0] != '=', sock_fd, &r);