#include "inspircd.h"
#include "configreader.h"
#include <signal.h>
-#ifndef WIN32
+#ifndef WIN32
#include <dirent.h>
#include <unistd.h>
#include <sys/resource.h>
-
+#include <dlfcn.h>
+#include <getopt.h>
/* This is just to be completely certain that the change which fixed getrusage on RH7 doesn't break anything else -- Om */
#ifndef RUSAGE_SELF
#define RUSAGE_SELF 0
#endif
-
#endif
+
#include <exception>
#include <fstream>
#include "modules.h"
#include "command_parse.h"
#include "exitcodes.h"
-#ifndef WIN32
-#include <dlfcn.h>
-#include <getopt.h>
-#else
+#ifdef WIN32
+
+/* This MUST remain static and delcared outside the class, so that WriteProcessMemory can reference it properly */
static DWORD owner_processid = 0;
DWORD WindowsForkStart(InspIRCd * Instance)
case 'f':
/* Log filename was set */
strlcpy(LogFileName, optarg, MAXBUF);
- if (owner_processid)
- printf("LOG: Setting logfile to %s\n", LogFileName);
break;
case 'c':
/* Config filename was set */
strlcpy(ConfigFileName, optarg, MAXBUF);
- if (owner_processid)
- printf("CONFIG: Setting config file to %s\n", ConfigFileName);
break;
case 0:
/* getopt_long_only() set an int variable, just keep going */