summaryrefslogtreecommitdiff
path: root/src/init.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/init.c')
-rw-r--r--src/init.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/init.c b/src/init.c
index f0212cc70..04f2e64b9 100644
--- a/src/init.c
+++ b/src/init.c
@@ -405,6 +405,9 @@ int openlog_failed = 0, openlog_errno = 0;
int init_primary(int ac, char **av)
{
int started_from_term = isatty(0) && isatty(1) && isatty(2);
+#ifdef _WIN32
+ char *winver;
+#endif
/* Set file creation mask and group ID. */
#if defined(DEFUMASK) && HAVE_UMASK
@@ -484,6 +487,13 @@ int init_secondary(int ac, char **av)
return -1;
}
}
+ if (!SupportedWindowsVersion()) {
+ winver = GetWindowsVersion();
+ alog("%s is not a supported version of Windows", winver);
+ free(winver);
+ return -1;
+ }
+
if (!nofork) {
alog("Launching Anope into the background");
FreeConsole();