aboutsummaryrefslogtreecommitdiffstats
path: root/code/sys
diff options
context:
space:
mode:
Diffstat (limited to 'code/sys')
-rw-r--r--code/sys/sys_main.c20
-rw-r--r--code/sys/win_resource.rc5
2 files changed, 14 insertions, 11 deletions
diff --git a/code/sys/sys_main.c b/code/sys/sys_main.c
index dcefa78..453b082 100644
--- a/code/sys/sys_main.c
+++ b/code/sys/sys_main.c
@@ -19,13 +19,11 @@ along with Quake III Arena source code; if not, write to the Free Software
Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
===========================================================================
*/
-#include <unistd.h>
+
#include <signal.h>
#include <stdlib.h>
#include <limits.h>
-#include <sys/time.h>
#include <sys/types.h>
-#include <unistd.h>
#include <stdarg.h>
#include <stdio.h>
#include <sys/stat.h>
@@ -34,8 +32,13 @@ Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
#include <errno.h>
#ifndef DEDICATED
-#include "SDL.h"
-#include "SDL_cpuinfo.h"
+#ifdef USE_LOCAL_HEADERS
+# include "SDL.h"
+# include "SDL_cpuinfo.h"
+#else
+# include <SDL.h>
+# include <SDL_cpuinfo.h>
+#endif
#endif
#include "sys_local.h"
@@ -163,10 +166,7 @@ void Sys_Exit( int ex )
#endif
#ifdef NDEBUG
- // _exit is called instead of exit since there are rumours of
- // GL libraries installing atexit calls that we don't want to call
- // FIXME: get some testing done with plain exit
- _exit(ex);
+ exit(ex);
#else
// Cause a backtrace on error exits
assert( ex == 0 );
@@ -436,7 +436,6 @@ void *Sys_LoadDll( const char *name, char *fqpath ,
{
void *libHandle;
void (*dllEntry)( intptr_t (*syscallptr)(intptr_t, ...) );
- char curpath[MAX_OSPATH];
char fname[MAX_OSPATH];
char *basepath;
char *homepath;
@@ -445,7 +444,6 @@ void *Sys_LoadDll( const char *name, char *fqpath ,
assert( name );
- getcwd(curpath, sizeof(curpath));
Q_snprintf (fname, sizeof(fname), "%s" ARCH_STRING DLL_EXT, name);
// TODO: use fs_searchpaths from files.c
diff --git a/code/sys/win_resource.rc b/code/sys/win_resource.rc
index 2654835..cbc9ce5 100644
--- a/code/sys/win_resource.rc
+++ b/code/sys/win_resource.rc
@@ -57,7 +57,12 @@ END
// Icon with lowest ID value placed first to ensure application icon
// remains consistent on all systems.
+#ifndef __MINGW32__
+IDI_ICON1 ICON DISCARDABLE "../quake3.ico"
+#else
IDI_ICON1 ICON DISCARDABLE "misc/quake3.ico"
+#endif
+
/////////////////////////////////////////////////////////////////////////////
//