From: Aaron Jones Date: Sat, 14 May 2016 23:29:33 +0000 (+0000) Subject: minor spring cleaning: remove/relocate duplicate/unused includes & macros X-Git-Url: https://jfr.im/git/solanum.git/commitdiff_plain/b143df9ac401c843a063f7fb8bb90fed786ff705 minor spring cleaning: remove/relocate duplicate/unused includes & macros [ci skip] --- diff --git a/authd/getaddrinfo.h b/authd/getaddrinfo.h index 9916629b..79581d92 100644 --- a/authd/getaddrinfo.h +++ b/authd/getaddrinfo.h @@ -83,10 +83,6 @@ struct rb_addrinfo { #define NI_DGRAM 0x00000010 #endif /* NI_DGRAM */ -#ifndef INADDR_NONE -#define INADDR_NONE ((unsigned int) 0xffffffff) -#endif /* INADDR_NONE */ - int rb_getaddrinfo(const char *hostname, const char *servname, const struct rb_addrinfo *hints, struct rb_addrinfo **res); void rb_freeaddrinfo(struct rb_addrinfo *ai); diff --git a/authd/reslist.c b/authd/reslist.c index 07f16e23..1a17ec2e 100644 --- a/authd/reslist.c +++ b/authd/reslist.c @@ -36,6 +36,9 @@ const char *get_windows_nameservers(void); +#ifndef INADDR_NONE +#define INADDR_NONE ((unsigned int) 0xffffffff) +#endif /* INADDR_NONE */ #define IS_NT() ((int)GetVersion() > 0) #define WIN_NS_9X "System\\CurrentControlSet\\Services\\VxD\\MSTCP" diff --git a/ircd/ircd.c b/ircd/ircd.c index 9bd415d2..998e2c87 100644 --- a/ircd/ircd.c +++ b/ircd/ircd.c @@ -53,7 +53,6 @@ #include "ircd_getopt.h" #include "newconf.h" #include "reject.h" -#include "s_conf.h" #include "s_newconf.h" #include "cache.h" #include "monitor.h" diff --git a/ircd/listener.c b/ircd/listener.c index cfc4ab14..ba4a1150 100644 --- a/ircd/listener.c +++ b/ircd/listener.c @@ -36,7 +36,6 @@ #include "send.h" #include "authproc.h" #include "reject.h" -#include "s_conf.h" #include "hostmask.h" #include "sslproc.h" #include "wsproc.h" @@ -44,10 +43,6 @@ #include "s_assert.h" #include "logger.h" -#ifndef INADDR_NONE -#define INADDR_NONE ((unsigned int) 0xffffffff) -#endif - #if defined(NO_IN6ADDR_ANY) && defined(RB_IPV6) static const struct in6_addr in6addr_any = { { { 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 } } }; @@ -444,8 +439,6 @@ close_listeners() } } -#define DLINE_WARNING "ERROR :You have been D-lined.\r\n" - /* * add_connection - creates a client which has just connected to us on * the given fd. The sockhost field is initialized with the ip# of the host. diff --git a/ircd/modules.c b/ircd/modules.c index 2cd59b6b..671bf641 100644 --- a/ircd/modules.c +++ b/ircd/modules.c @@ -287,8 +287,6 @@ load_one_module(const char *path, int origin, bool coremodule) static void increase_modlist(void); -#define MODS_INCREMENT 10 - static char unknown_ver[] = ""; static char unknown_description[] = ""; diff --git a/ircd/s_conf.c b/ircd/s_conf.c index 94bb8a4f..2a7d5b97 100644 --- a/ircd/s_conf.c +++ b/ircd/s_conf.c @@ -58,10 +58,6 @@ struct config_server_hide ConfigServerHide; extern int yyparse(void); /* defined in y.tab.c */ extern char linebuf[]; -#ifndef INADDR_NONE -#define INADDR_NONE ((unsigned int) 0xffffffff) -#endif - static rb_bh *confitem_heap = NULL; rb_dlink_list prop_bans; diff --git a/ircd/s_serv.c b/ircd/s_serv.c index 6f43537f..7b5d15cb 100644 --- a/ircd/s_serv.c +++ b/ircd/s_serv.c @@ -53,10 +53,6 @@ #include "capability.h" #include "s_assert.h" -#ifndef INADDR_NONE -#define INADDR_NONE ((unsigned int) 0xffffffff) -#endif - int MaxConnectionCount = 1; int MaxClientCount = 1; int refresh_user_links = 0;