]> de.git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - sys_shared.c
-Removed the NG Menu part, since it isnt used anymore (the old layout
[xonotic/darkplaces.git] / sys_shared.c
index 258e6cf45c1aacffc99ce8f8392318f3e08f5af6..1893c219f460ebbdf49145a8ed8fa530e06575eb 100644 (file)
@@ -72,7 +72,7 @@ void Sys_Print(const char *msg)
        if (timestamps.integer)
                snprintf(final, sizeof(final), "%s%s", Sys_TimeString(timeformat.string), msg);
        else
-               strncpy(final, msg, sizeof(final));
+               strlcpy (final, msg, sizeof (final));
 
        // LordHavoc: make sure the string is terminated
        final[MAXPRINTMSG-1] = 0;
@@ -93,6 +93,13 @@ void Sys_Printf(const char *fmt, ...)
        Sys_Print(msg);
 }
 
+extern qboolean host_shuttingdown;
+void Sys_Quit (void)
+{
+       host_shuttingdown = true;
+       Host_Shutdown();
+       exit(0);
+}
 
 char engineversion[128];
 
@@ -109,6 +116,8 @@ void Sys_Shared_EarlyInit(void)
        os = "Linux";
 #elif defined(WIN32)
        os = "Windows";
+#elif defined(__FreeBSD__)
+       os = "FreeBSD";
 #elif defined(__NetBSD__)
        os = "NetBSD";
 #elif defined(__OpenBSD__)
@@ -118,6 +127,7 @@ void Sys_Shared_EarlyInit(void)
 #endif
        snprintf (engineversion, sizeof (engineversion), "%s %s %s", gamename, os, buildstring);
 
+// COMMANDLINEOPTION: Console: -nostdout disables text output to the terminal the game was launched from
        if (COM_CheckParm("-nostdout"))
                sys_nostdout = 1;
        else