diff --git a/build/win32/Cxbe.dsp b/build/win32/Cxbe.dsp
deleted file mode 100644
index d278b5958..000000000
--- a/build/win32/Cxbe.dsp
+++ /dev/null
@@ -1,141 +0,0 @@
-# Microsoft Developer Studio Project File - Name="Cxbe" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 60000
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Console Application" 0x0103
-
-CFG=Cxbe - Win32 Debug
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE
-!MESSAGE NMAKE /f "Cxbe.mak".
-!MESSAGE
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE
-!MESSAGE NMAKE /f "Cxbe.mak" CFG="Cxbe - Win32 Debug"
-!MESSAGE
-!MESSAGE Possible choices for configuration are:
-!MESSAGE
-!MESSAGE "Cxbe - Win32 Release" (based on "Win32 (x86) Console Application")
-!MESSAGE "Cxbe - Win32 Debug" (based on "Win32 (x86) Console Application")
-!MESSAGE
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName "Cxbe"
-# PROP Scc_LocalPath "."
-CPP=cl.exe
-RSC=rc.exe
-
-!IF "$(CFG)" == "Cxbe - Win32 Release"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release"
-# PROP BASE Intermediate_Dir "Release"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "..\..\bin\release"
-# PROP Intermediate_Dir "..\..\bin\release"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "..\..\src" /I "..\..\src\Common\Win32" /I "..\..\src\Win32" /D "WIN32" /D "NDEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /c
-# ADD BASE RSC /l 0x409 /d "NDEBUG"
-# ADD RSC /l 0x409 /d "NDEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /machine:I386
-# SUBTRACT LINK32 /pdb:none
-
-!ELSEIF "$(CFG)" == "Cxbe - Win32 Debug"
-
-# PROP BASE Use_MFC 0
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug"
-# PROP BASE Intermediate_Dir "Debug"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 0
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "..\..\bin\debug"
-# PROP Intermediate_Dir "..\..\bin\debug"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
-# ADD CPP /nologo /MDd /W3 /Gm /GX /Zi /Od /I "..\..\src" /I "..\..\src\Common\Win32" /D "WIN32" /D "_DEBUG" /D "_CONSOLE" /D "_MBCS" /YX /FD /GZ /c
-# SUBTRACT CPP /Fr
-# ADD BASE RSC /l 0x409 /d "_DEBUG"
-# ADD RSC /l 0x409 /d "_DEBUG"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib /nologo /subsystem:console /map /debug /machine:I386 /pdbtype:sept
-# SUBTRACT LINK32 /pdb:none
-
-!ENDIF
-
-# Begin Target
-
-# Name "Cxbe - Win32 Release"
-# Name "Cxbe - Win32 Debug"
-# Begin Group "Include"
-
-# PROP Default_Filter ""
-# Begin Source File
-
-SOURCE=..\..\src\Common\Win32\AlignPosfix1.h
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\src\Common\Win32\AlignPrefix1.h
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\src\Cxbx.h
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\src\Common\Error.h
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\src\Common\Exe.h
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\src\Common\Xbe.h
-# End Source File
-# End Group
-# Begin Group "Source"
-
-# PROP Default_Filter ""
-# Begin Source File
-
-SOURCE=..\..\src\Common\Error.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\src\Common\Exe.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\src\Cxbe\Main.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\src\Common\OpenXDK.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=..\..\src\Common\Xbe.cpp
-# End Source File
-# End Group
-# End Target
-# End Project
diff --git a/build/win32/Cxbe.vcproj b/build/win32/Cxbe.vcproj
new file mode 100755
index 000000000..9c9d0f7ea
--- /dev/null
+++ b/build/win32/Cxbe.vcproj
@@ -0,0 +1,347 @@
+
+ UPX is a portable, extendable, high-performance executable packer for
several different executable formats. It achieves an excellent compression
@@ -107,8 +107,8 @@ releases will be backward compatible with this version. -q -q -q (or -qqq): produce no output at all --help: prints the help --version: print the version of UPX --exact: when compressing, require to be able to get a byte-identical file
+after decompression with option -d. [NOTE: this is work in progress and is
+not supported for all formats yet. If you do care, as a workaround you can
+compress and then decompress your program a first time - any further
+compress-decompress steps should then yield byte-identical results
+as compared to the first decompressed version.] [ ...to be written... - type `upx --help' for now ]
UPX offers ten different compression levels from -1 to -9,
and --best. The default compression level is -8 for files
-smaller than 512 kB, and -7 otherwise.
-
-->
@@ -77,7 +77,7 @@
+
-
-
+
+
-
-
+ ABSTRACT
The Ultimate Packer for eXecutables
- Copyright (c) 1996-2006 Markus Oberhumer, Laszlo Molnar & John Reiser
+ Copyright (c) 1996-2008 Markus Oberhumer, Laszlo Molnar & John Reiser
http://upx.sourceforge.net
- - very fast decompression: about 10 MB/sec on an ancient Pentium 133,
- about 200 MB/sec on an Athlon XP 2000+.
+ - very fast decompression: about 10 MiB/sec on an ancient Pentium 133,
+ about 200 MiB/sec on an Athlon XP 2000+.
- no memory overhead for your compressed executables for most of the
supported formats
@@ -187,6 +187,12 @@ shows the compressed / uncompressed size and the compression ratio of
COMPRESSION LEVELS & TUNING
Compression levels 1, 2 and 3 are pretty fast.
@@ -212,25 +218,10 @@ smaller than 512 kB, and -7 otherwise.Note that compression level --best can be somewhat slow for large files, but you definitely should use it when releasing a final version of your program.
-Quick start for achieving the best compression ratio:
-Try upx --brute myfile.exe.
-Details for achieving the best compression ratio:
+Quick info for achieving the best compression ratio:
Use the compression level --best.
-Try one or both of the options --all-methods and --all-filters.
-Try the option --crp-ms=NUMBER. This uses more memory during compression -to achieve a (slightly) better compression ratio.
-NUMBER must be a decimal value from 10000 to 999999, inclusive. -The default value is 10000 (ten thousand).
-Info: the option --brute is an abbrevation for the options ---best --all-methods --all-filters --crp-ms=999999.
+Try upx --brute myfile.exe or even upx --ultra-brute myfile.exe.
Try if --overlay=strip works.
@@ -243,7 +234,7 @@ The default value is 10000 (ten thousand).Info: An ``overlay'' means auxillary data atached after the logical end of +
Info: An ``overlay'' means auxiliary data attached after the logical end of an executable, and it often contains application specific data (this is a common practice to avoid an extra data file, though it would be better to use resource sections).
@@ -364,7 +355,7 @@ themselves (like some command line utilities that ship with Win95/98/ME).First of all, it is recommended to use UPX *instead* of strip. strip has the very bad habit of replacing your stub with its own (outdated) version. Additionally UPX corrects a bug/feature in strip v2.8.x: it -will fix the 4 KByte aligment of the stub.
+will fix the 4 KiB alignment of the stub.UPX includes the full functionality of stubify. This means it will automatically stubify your COFF files. Use the option --coff to disable this functionality (see below).
@@ -392,7 +383,7 @@ All debug information and trailing garbage will be stripped, though.Introduction
Linux/386 support in UPX consists of 3 different executable formats, - one optimized for ELF excutables ("linux/elf386"), one optimized + one optimized for ELF executables ("linux/elf386"), one optimized for shell scripts ("linux/sh386"), and one generic format ("linux/386").
@@ -419,14 +410,14 @@ All debug information and trailing garbage will be stripped, though. or network I/O.
Depending on the statistics of usage and access, and the relative - speeds of CPU, RAM, swap space, /tmp, and filesystem storage, then + speeds of CPU, RAM, swap space, /tmp, and file system storage, then invoking and running a compressed executable can be faster than directly running the corresponding uncompressed program. - The operating system might perfrom fewer expensive I/O operations + The operating system might perform fewer expensive I/O operations to invoke the compressed program. Paging to or from swap space - or /tmp might be faster than paging from the general filesystem. + or /tmp might be faster than paging from the general file system. ``Medium-sized'' programs which access about 1/3 to 1/2 of their - stored program bytes can do particulary well with compression. + stored program bytes can do particularly well with compression. Small programs tend not to benefit as much because the absolute savings is less. Big programs tend not to benefit proportionally because each invocation may use only a small fraction of the program, @@ -435,7 +426,7 @@ All debug information and trailing garbage will be stripped, though. then compression may win anyway.
Currently, executables compressed by UPX do not share RAM at runtime - in the way that executables mapped from a filesystem do. As a + in the way that executables mapped from a file system do. As a result, if the same program is run simultaneously by more than one process, then using the compressed version will require more RAM and/or swap space. So, shell programs (bash, csh, etc.) and ``make'' @@ -517,7 +508,7 @@ All debug information and trailing garbage will be stripped, though.The linux/elf386 format decompresses directly into RAM, uses only one exec, does not use space in /tmp, and does not use /proc.
-Linux/elf386 is automatically selected for Linux ELF exectuables.
+Linux/elf386 is automatically selected for Linux ELF executables.
Packed programs will be byte-identical to the original after uncompression.
How it works:
@@ -591,7 +582,7 @@ use a known shell.NOTES FOR LINUX/386
Please read the general Linux description first.
The generic linux/386 format decompresses to /tmp and needs -/proc filesystem support. It starts the decompressed program +/proc file system support. It starts the decompressed program via the
execve()
syscall.Linux/386 is only selected if the specialized linux/elf386 and linux/sh386 won't recognize a file.
@@ -600,11 +591,11 @@ and linux/sh386 won't recognize a file.For files which are not ELF and not a script for a known "-c" shell, UPX uses kernel execve(), which first requires decompressing to a - temporary file in the filesystem. Interestingly - + temporary file in the file system. Interestingly - because of the good memory management of the Linux kernel - this - often does not introduce a noticable delay, and in fact there + often does not introduce a noticeable delay, and in fact there will be no disk access at all if you have enough free memory as - the entire process takes places within the filesystem buffers.+ the entire process takes places within the file system buffers.A compressed executable consists of the UPX stub and an overlay which contains the original program in a compressed form.@@ -629,7 +620,7 @@ and linux/sh386 won't recognize a file. decompression, but you still need it for the full execution time of the program.
- - You must have /proc filesystem support as the stub wants to open + - You must have /proc file system support as the stub wants to open /proc/<pid>/exe and needs /proc/<pid>/fd/X. This also means that you cannot compress programs that are used during the boot sequence before /proc is mounted.@@ -641,8 +632,8 @@ and linux/sh386 won't recognize a file.
- Because of temporary decompression to disk the decompression speed is not as fast as with the other executable formats. Still, I can see - no noticable delay when starting programs like my ~3 MB emacs (which - is less than 1 MB when compressed :-).+ no noticeable delay when starting programs like my ~3 MiB emacs (which + is less than 1 MiB when compressed :-).
Extra options available for this executable format:
--force-execve Force the use of the generic linux/386 "execve" @@ -657,18 +648,22 @@ Support of this format is very similar to the Atari one, because of nostalgic feelings of one of the authors.Packed programs will be byte-identical to the original after uncompression, until further notice.
-Maximum uncompressed size: ~1998848 bytes.
+Maximum uncompressed size: ~1.89 / ~7.60 MiB.
Notes:
- - UPX creates as default a 'CD-Rom only' PS1/PS2 compatible executable. - For transfer between client/target use options below.+ - UPX creates as default a suitable executable for CD-Mastering + and console transfer. For a CD-Master main executable you could also try + the special option "--boot-only" as described below. + It has been reported that upx packed executables are fully compatible with + the Sony PlayStation 2 (PS2, PStwo) and Sony PlayStation Portable (PSP) in + Sony PlayStation (PSone) emulation mode.
- Normally the packed files use the same memory areas like the uncompressed versions, so they will not override other memory areas while unpacking. If this isn't possible UPX will abort showing a 'packed data overlap' - error. With the "--force" option UPX will set a few 'bytes higher' loading - offset for the packed file, but this isn't a real problem if it is a - single or boot-only executable.+ error. With the "--force" option UPX will relocate the loading address + for the packed file, but this isn't a real problem if it is a single or + the main executable.
Extra options available for this executable format:
--all-methods Compress the program several times, using all @@ -676,15 +671,19 @@ until further notice. the compression ratio in some cases, but usually the default method gives the best results anyway.
- --boot-only The format will only run from a CD and may slightly - improves the compression ratio. The decompression - routines are faster than default ones. - But it cannot be used for host/client transfer !+ --8-bit Uses 8 bit size compression [default: 32 bit] +
+ --8mib-ram PSone has 8 MiB ram available [default: 2 MiB]+
+ --boot-only This format is for main exes and CD-Mastering only ! + It may slightly improve the compression ratio, + decompression routines are faster than default ones. + But it cannot be used for console transfer !
--no-align This option disables CD mode 2 data sector format alignment. May slightly improves the compression ratio, but the compressed executable will not boot from a CD. - Use it for client/target transfer only !+ Use it for console transfer only !
For example, this is what I get for my 2.2.16 kernel: 1589708 vmlinux @@ -761,12 +760,12 @@ formats, and it does not share any of their drawbacks.NOTES FOR WIN32/PE
The PE support in UPX is quite stable now, but probably there are -still some incompabilities with some files.
+still some incompatibilities with some files.Because of the way UPX (and other packers for this format) works, you can see increased memory usage of your compressed files because the whole program is loaded into memory at startup. If you start several instances of huge compressed programs you're -wasting memory because the common segements of the program won't +wasting memory because the common segments of the program won't get shared across the instances. On the other hand if you're compressing only smaller programs, or running only one instance of larger programs, then this penalty is @@ -780,8 +779,8 @@ application may be a better idea.
Screensavers are supported, with the restriction that the filename must end with ``.scr'' (as screensavers are handled slightly different than normal exe files).
-UPX compressed PE files has some minor memory overhead (usually in the -10 - 30 kbytes range) which can be seen by specifying the ``-i'' command +
UPX compressed PE files have some minor memory overhead (usually in the +10 - 30 KiB range) which can be seen by specifying the ``-i'' command line switch during compression.
Extra options available for this executable format:
@@ -798,7 +797,8 @@ line switch during compression. --compress-icons=0 Don't compress any icons. --compress-icons=1 Compress all but the first icon. --compress-icons=2 Compress all icons which are not in the - first icon directory. [DEFAULT]+ first icon directory. [DEFAULT] + --compress-icons=3 Compress all icons.
--compress-resources=0 Don't compress any resources at all.
@@ -870,10 +870,10 @@ is 1. If a warning occurs, exit status is 2.
COPYRIGHT
-Copyright (C) 1996-2006 Markus Franz Xaver Johannes Oberhumer
-Copyright (C) 1996-2006 Laszlo Molnar
-Copyright (C) 2000-2006 John F. Reiser
-Copyright (C) 2002-2006 Jens Medoch
+Copyright (C) 1996-2008 Markus Franz Xaver Johannes Oberhumer
+Copyright (C) 1996-2008 Laszlo Molnar
+Copyright (C) 2000-2008 John F. Reiser
+Copyright (C) 2002-2008 Jens Medoch
This program may be used freely, and you are welcome to redistribute it under certain conditions.
This program is distributed in the hope that it will be useful, diff --git a/resource/Cxbx.rc b/resource/Cxbx.rc index 97388012b..c829aaab8 100644 --- a/resource/Cxbx.rc +++ b/resource/Cxbx.rc @@ -7,7 +7,11 @@ // // Generated from the TEXTINCLUDE 2 resource. // -#include "afxres.h" +#include "WinResrc.h" + +#ifndef IDC_STATIC +#define IDC_STATIC -1 +#endif // IDC_STATIC ///////////////////////////////////////////////////////////////////////////// #undef APSTUDIO_READONLY_SYMBOLS @@ -43,7 +47,7 @@ END 2 TEXTINCLUDE DISCARDABLE BEGIN - "#include ""afxres.h""\r\n" + "#include ""WinResrc.h""\r\n" "\0" END diff --git a/resource/CxbxDll.rc b/resource/CxbxDll.rc index abe4a23eb..cab3f5cfb 100644 --- a/resource/CxbxDll.rc +++ b/resource/CxbxDll.rc @@ -7,7 +7,11 @@ // // Generated from the TEXTINCLUDE 2 resource. // -#include "afxres.h" +#include "WinResrc.h" + +#ifndef IDC_STATIC +#define IDC_STATIC -1 +#endif // IDC_STATIC ///////////////////////////////////////////////////////////////////////////// #undef APSTUDIO_READONLY_SYMBOLS @@ -34,7 +38,7 @@ END 2 TEXTINCLUDE DISCARDABLE BEGIN - "#include ""afxres.h""\r\n" + "#include ""WinResrc.h""\r\n" "\0" END diff --git a/src/CxbxKrnl/CxbxKrnl.cpp b/src/CxbxKrnl/CxbxKrnl.cpp index f6ad7c4a6..43194873a 100644 --- a/src/CxbxKrnl/CxbxKrnl.cpp +++ b/src/CxbxKrnl/CxbxKrnl.cpp @@ -195,7 +195,7 @@ extern "C" CXBXKRNL_API void CxbxKrnlInit else GetCurrentDirectory(260, szBuffer); - g_strCurDrive = strdup(szBuffer); + g_strCurDrive = _strdup(szBuffer); g_hCurDir = CreateFile(szBuffer, GENERIC_READ, FILE_SHARE_READ, NULL, OPEN_EXISTING, FILE_FLAG_BACKUP_SEMANTICS, NULL); @@ -251,7 +251,7 @@ extern "C" CXBXKRNL_API void CxbxKrnlInit CreateDirectory(szBuffer, NULL); - g_strTDrive = strdup(szBuffer); + g_strTDrive = _strdup(szBuffer); g_hTDrive = CreateFile(szBuffer, GENERIC_READ, FILE_SHARE_READ, NULL, OPEN_EXISTING, FILE_FLAG_BACKUP_SEMANTICS, NULL); @@ -274,7 +274,7 @@ extern "C" CXBXKRNL_API void CxbxKrnlInit CreateDirectory(szBuffer, NULL); - g_strUDrive = strdup(szBuffer); + g_strUDrive = _strdup(szBuffer); g_hUDrive = CreateFile(szBuffer, GENERIC_READ, FILE_SHARE_READ, NULL, OPEN_EXISTING, FILE_FLAG_BACKUP_SEMANTICS, NULL); @@ -299,7 +299,7 @@ extern "C" CXBXKRNL_API void CxbxKrnlInit CreateDirectory(szBuffer, NULL); //*/ - g_strZDrive = strdup(szBuffer); + g_strZDrive = _strdup(szBuffer); g_hZDrive = CreateFile(szBuffer, GENERIC_READ, FILE_SHARE_READ, NULL, OPEN_EXISTING, FILE_FLAG_BACKUP_SEMANTICS, NULL); diff --git a/src/CxbxKrnl/DbgConsole.cpp b/src/CxbxKrnl/DbgConsole.cpp index 7cba5661b..7884999ef 100644 --- a/src/CxbxKrnl/DbgConsole.cpp +++ b/src/CxbxKrnl/DbgConsole.cpp @@ -184,7 +184,7 @@ void DbgConsole::ParseCommand() // TODO: as command list grows, turn into static string/ptr lookup - if(stricmp(szCmd, "h") == 0 || stricmp(szCmd, "help") == 0) + if(_stricmp(szCmd, "h") == 0 || _stricmp(szCmd, "help") == 0) { printf("CxbxDbg: \n"); printf("CxbxDbg: Cxbx Debug Command List:\n"); @@ -217,18 +217,18 @@ void DbgConsole::ParseCommand() printf("CxbxDbg: # denotes parameter of form [#] or [#-#]\n"); printf("CxbxDbg: \n"); } - else if(stricmp(szCmd, "q") == 0 || stricmp(szCmd, "quit") == 0 || stricmp(szCmd, "exit") == 0) + else if(_stricmp(szCmd, "q") == 0 || _stricmp(szCmd, "quit") == 0 || _stricmp(szCmd, "exit") == 0) { printf("CxbxDbg: Goodbye...\n"); CxbxKrnlCleanup(NULL); } - else if(stricmp(szCmd, "t") == 0 || stricmp(szCmd, "trace") == 0) + else if(_stricmp(szCmd, "t") == 0 || _stricmp(szCmd, "trace") == 0) { g_bPrintfOn = !g_bPrintfOn; printf("CxbxDbg: Trace is now %s\n", g_bPrintfOn ? "ON" : "OFF"); } #ifdef _DEBUG_TRACK_VB - else if(stricmp(szCmd, "lvb") == 0 || stricmp(szCmd, "ListVB") == 0) + else if(_stricmp(szCmd, "lvb") == 0 || _stricmp(szCmd, "ListVB") == 0) { int v=0; @@ -247,7 +247,7 @@ void DbgConsole::ParseCommand() g_VBTrackTotal.Unlock(); } - else if(stricmp(szCmd, "dvb") == 0 || stricmp(szCmd, "DisableVB") == 0) + else if(_stricmp(szCmd, "dvb") == 0 || _stricmp(szCmd, "DisableVB") == 0) { int n=0, m=0; @@ -266,7 +266,7 @@ void DbgConsole::ParseCommand() printf("CxbxDbg: Syntax Incorrect (dvb #)\n"); } } - else if(stricmp(szCmd, "evb") == 0 || stricmp(szCmd, "EnableVB") == 0) + else if(_stricmp(szCmd, "evb") == 0 || _stricmp(szCmd, "EnableVB") == 0) { int n=0, m=0; @@ -285,13 +285,13 @@ void DbgConsole::ParseCommand() printf("CxbxDbg: Syntax Incorrect (dvb #)\n"); } } - else if(stricmp(szCmd, "dsc") == 0 || stricmp(szCmd, "DumpStreamCache") == 0) + else if(_stricmp(szCmd, "dsc") == 0 || _stricmp(szCmd, "DumpStreamCache") == 0) { XTL::VertexPatcher::DumpCache(); } #endif #ifdef _DEBUG_TRACK_PB - else if(stricmp(szCmd, "lpb") == 0 || stricmp(szCmd, "ListPB") == 0) + else if(_stricmp(szCmd, "lpb") == 0 || _stricmp(szCmd, "ListPB") == 0) { int v=0; @@ -310,7 +310,7 @@ void DbgConsole::ParseCommand() g_PBTrackTotal.Unlock(); } - else if(stricmp(szCmd, "spb") == 0 || stricmp(szCmd, "ShowPB") == 0) + else if(_stricmp(szCmd, "spb") == 0 || _stricmp(szCmd, "ShowPB") == 0) { int n=0, m=0; @@ -329,7 +329,7 @@ void DbgConsole::ParseCommand() printf("CxbxDbg: Syntax Incorrect (spb #)\n"); } } - else if(stricmp(szCmd, "dpb") == 0 || stricmp(szCmd, "DisablePB") == 0) + else if(_stricmp(szCmd, "dpb") == 0 || _stricmp(szCmd, "DisablePB") == 0) { int n=0, m=0; @@ -348,7 +348,7 @@ void DbgConsole::ParseCommand() printf("CxbxDbg: Syntax Incorrect (dpb #)\n"); } } - else if(stricmp(szCmd, "epb") == 0 || stricmp(szCmd, "EnablePB") == 0) + else if(_stricmp(szCmd, "epb") == 0 || _stricmp(szCmd, "EnablePB") == 0) { int n=0, m=0; @@ -367,7 +367,7 @@ void DbgConsole::ParseCommand() printf("CxbxDbg: Syntax Incorrect (dpb #)\n"); } } - else if(stricmp(szCmd, "cpb") == 0 || stricmp(szCmd, "ClearPB") == 0) + else if(_stricmp(szCmd, "cpb") == 0 || _stricmp(szCmd, "ClearPB") == 0) { g_PBTrackTotal.clear(); @@ -375,14 +375,14 @@ void DbgConsole::ParseCommand() } #endif #ifdef _DEBUG_ALLOC - else if(stricmp(szCmd, "dmem") == 0 || stricmp(szCmd, "DumpMem") == 0) + else if(_stricmp(szCmd, "dmem") == 0 || _stricmp(szCmd, "DumpMem") == 0) { int Full; int c = sscanf(m_szInput, "%*s %d", &Full); CxbxAllocDump(Full != 0); } #endif // _DEBUG_ALLOC - else if(stricmp(szCmd, "cls") == 0) + else if(_stricmp(szCmd, "cls") == 0) { // clear screen using system call system("cls"); diff --git a/src/CxbxKrnl/EmuD3D8/VertexBuffer.h b/src/CxbxKrnl/EmuD3D8/VertexBuffer.h index f156619d7..a19121c33 100644 --- a/src/CxbxKrnl/EmuD3D8/VertexBuffer.h +++ b/src/CxbxKrnl/EmuD3D8/VertexBuffer.h @@ -85,6 +85,9 @@ class VertexPatcher bool Apply(VertexPatchDesc *pPatchDesc); bool Restore(); + // Dumps the cache to the console + static void DumpCache(void); + private: UINT m_uiNbrStreams; @@ -100,9 +103,6 @@ class VertexPatcher // Returns the number of streams of a patch UINT GetNbrStreams(VertexPatchDesc *pPatchDesc); - // Dumps the cache to the console - static void DumpCache(void); - // Caches a patched stream void CacheStream(VertexPatchDesc *pPatchDesc, UINT uiStream); diff --git a/src/CxbxKrnl/EmuKrnl.cpp b/src/CxbxKrnl/EmuKrnl.cpp index 23e9860af..8335fa7cc 100644 --- a/src/CxbxKrnl/EmuKrnl.cpp +++ b/src/CxbxKrnl/EmuKrnl.cpp @@ -218,7 +218,7 @@ XBSYSAPI EXPORTNUM(15) xboxkrnl::PVOID NTAPI xboxkrnl::ExAllocatePoolWithTag // ****************************************************************** // * 0x0018 ExQueryNonVolatileSetting // ****************************************************************** -XBSYSAPI EXPORTNUM(24) NTSTATUS NTAPI xboxkrnl::ExQueryNonVolatileSetting +XBSYSAPI EXPORTNUM(24) xboxkrnl::NTSTATUS NTAPI xboxkrnl::ExQueryNonVolatileSetting ( IN DWORD ValueIndex, OUT DWORD *Type, @@ -380,7 +380,7 @@ XBSYSAPI EXPORTNUM(49) VOID DECLSPEC_NORETURN xboxkrnl::HalReturnToFirmware // ****************************************************************** // * 0x0042 - IoCreateFile // ****************************************************************** -XBSYSAPI EXPORTNUM(66) NTSTATUS NTAPI xboxkrnl::IoCreateFile +XBSYSAPI EXPORTNUM(66) xboxkrnl::NTSTATUS NTAPI xboxkrnl::IoCreateFile ( OUT PHANDLE FileHandle, IN ACCESS_MASK DesiredAccess, @@ -425,7 +425,7 @@ XBSYSAPI EXPORTNUM(66) NTSTATUS NTAPI xboxkrnl::IoCreateFile // ****************************************************************** // * 0x0043 IoCreateSymbolicLink // ****************************************************************** -XBSYSAPI EXPORTNUM(67) NTSTATUS NTAPI xboxkrnl::IoCreateSymbolicLink +XBSYSAPI EXPORTNUM(67) xboxkrnl::NTSTATUS NTAPI xboxkrnl::IoCreateSymbolicLink ( IN PSTRING SymbolicLinkName, IN PSTRING DeviceName @@ -452,7 +452,7 @@ XBSYSAPI EXPORTNUM(67) NTSTATUS NTAPI xboxkrnl::IoCreateSymbolicLink // ****************************************************************** // * 0x0045 - IoDeleteSymbolicLink // ****************************************************************** -XBSYSAPI EXPORTNUM(69) NTSTATUS NTAPI xboxkrnl::IoDeleteSymbolicLink +XBSYSAPI EXPORTNUM(69) xboxkrnl::NTSTATUS NTAPI xboxkrnl::IoDeleteSymbolicLink ( IN PSTRING SymbolicLinkName ) @@ -476,7 +476,7 @@ XBSYSAPI EXPORTNUM(69) NTSTATUS NTAPI xboxkrnl::IoDeleteSymbolicLink // ****************************************************************** // * 0x0063 - KeDelayExecutionThread // ****************************************************************** -XBSYSAPI EXPORTNUM(99) NTSTATUS NTAPI xboxkrnl::KeDelayExecutionThread +XBSYSAPI EXPORTNUM(99) xboxkrnl::NTSTATUS NTAPI xboxkrnl::KeDelayExecutionThread ( IN KPROCESSOR_MODE WaitMode, IN BOOLEAN Alertable, @@ -921,7 +921,7 @@ XBSYSAPI EXPORTNUM(171) VOID NTAPI xboxkrnl::MmFreeContiguousMemory // ****************************************************************** // * 0x00AC - MmFreeSystemMemory // ****************************************************************** -XBSYSAPI EXPORTNUM(172) NTSTATUS NTAPI xboxkrnl::MmFreeSystemMemory +XBSYSAPI EXPORTNUM(172) xboxkrnl::NTSTATUS NTAPI xboxkrnl::MmFreeSystemMemory ( PVOID BaseAddress, ULONG NumberOfBytes @@ -995,7 +995,7 @@ XBSYSAPI EXPORTNUM(180) XTL::ULONG NTAPI xboxkrnl::MmQueryAllocationSize // ****************************************************************** // * 0x00B5 - MmQueryStatistics // ****************************************************************** -XBSYSAPI EXPORTNUM(181) NTSTATUS NTAPI xboxkrnl::MmQueryStatistics +XBSYSAPI EXPORTNUM(181) xboxkrnl::NTSTATUS NTAPI xboxkrnl::MmQueryStatistics ( OUT PMM_STATISTICS MemoryStatistics ) @@ -1071,7 +1071,7 @@ XBSYSAPI EXPORTNUM(182) VOID NTAPI xboxkrnl::MmSetAddressProtect // ****************************************************************** // * 0x00B8 - NtAllocateVirtualMemory // ****************************************************************** -XBSYSAPI EXPORTNUM(184) NTSTATUS NTAPI xboxkrnl::NtAllocateVirtualMemory +XBSYSAPI EXPORTNUM(184) xboxkrnl::NTSTATUS NTAPI xboxkrnl::NtAllocateVirtualMemory ( IN OUT PVOID *BaseAddress, IN ULONG ZeroBits, @@ -1102,7 +1102,7 @@ XBSYSAPI EXPORTNUM(184) NTSTATUS NTAPI xboxkrnl::NtAllocateVirtualMemory // ****************************************************************** // * 0x00BA - NtClearEvent // ****************************************************************** -XBSYSAPI EXPORTNUM(186) NTSTATUS NTAPI xboxkrnl::NtClearEvent +XBSYSAPI EXPORTNUM(186) xboxkrnl::NTSTATUS NTAPI xboxkrnl::NtClearEvent ( IN HANDLE EventHandle ) @@ -1128,7 +1128,7 @@ XBSYSAPI EXPORTNUM(186) NTSTATUS NTAPI xboxkrnl::NtClearEvent // ****************************************************************** // * 0x00BB - NtClose // ****************************************************************** -XBSYSAPI EXPORTNUM(187) NTSTATUS NTAPI xboxkrnl::NtClose +XBSYSAPI EXPORTNUM(187) xboxkrnl::NTSTATUS NTAPI xboxkrnl::NtClose ( IN HANDLE Handle ) @@ -1166,7 +1166,7 @@ XBSYSAPI EXPORTNUM(187) NTSTATUS NTAPI xboxkrnl::NtClose // ****************************************************************** // * 0x00BD - NtCreateEvent // ****************************************************************** -XBSYSAPI EXPORTNUM(189) NTSTATUS NTAPI xboxkrnl::NtCreateEvent +XBSYSAPI EXPORTNUM(189) xboxkrnl::NTSTATUS NTAPI xboxkrnl::NtCreateEvent ( OUT PHANDLE EventHandle, IN POBJECT_ATTRIBUTES ObjectAttributes OPTIONAL, @@ -1222,7 +1222,7 @@ XBSYSAPI EXPORTNUM(189) NTSTATUS NTAPI xboxkrnl::NtCreateEvent // ****************************************************************** // * 0x00BE - NtCreateFile // ****************************************************************** -XBSYSAPI EXPORTNUM(190) NTSTATUS NTAPI xboxkrnl::NtCreateFile +XBSYSAPI EXPORTNUM(190) xboxkrnl::NTSTATUS NTAPI xboxkrnl::NtCreateFile ( OUT PHANDLE FileHandle, IN ACCESS_MASK DesiredAccess, @@ -1386,7 +1386,7 @@ XBSYSAPI EXPORTNUM(190) NTSTATUS NTAPI xboxkrnl::NtCreateFile // ****************************************************************** // * 0x00C0 - NtCreateMutant // ****************************************************************** -XBSYSAPI EXPORTNUM(192) NTSTATUS NTAPI xboxkrnl::NtCreateMutant +XBSYSAPI EXPORTNUM(192) xboxkrnl::NTSTATUS NTAPI xboxkrnl::NtCreateMutant ( OUT PHANDLE MutantHandle, IN POBJECT_ATTRIBUTES ObjectAttributes, @@ -1439,7 +1439,7 @@ XBSYSAPI EXPORTNUM(192) NTSTATUS NTAPI xboxkrnl::NtCreateMutant // ****************************************************************** // * 0x00C5 - NtDuplicateObject // ****************************************************************** -XBSYSAPI EXPORTNUM(197) NTSTATUS NTAPI xboxkrnl::NtDuplicateObject +XBSYSAPI EXPORTNUM(197) xboxkrnl::NTSTATUS NTAPI xboxkrnl::NtDuplicateObject ( HANDLE SourceHandle, HANDLE *TargetHandle, @@ -1477,7 +1477,7 @@ XBSYSAPI EXPORTNUM(197) NTSTATUS NTAPI xboxkrnl::NtDuplicateObject // ****************************************************************** // * NtFlushBuffersFile // ****************************************************************** -XBSYSAPI EXPORTNUM(198) NTSTATUS NTAPI xboxkrnl::NtFlushBuffersFile +XBSYSAPI EXPORTNUM(198) xboxkrnl::NTSTATUS NTAPI xboxkrnl::NtFlushBuffersFile ( PVOID FileHandle, OUT PIO_STATUS_BLOCK IoStatusBlock @@ -1502,7 +1502,7 @@ XBSYSAPI EXPORTNUM(198) NTSTATUS NTAPI xboxkrnl::NtFlushBuffersFile // ****************************************************************** // * 0x00C7 - NtFreeVirtualMemory // ****************************************************************** -XBSYSAPI EXPORTNUM(199) NTSTATUS NTAPI xboxkrnl::NtFreeVirtualMemory +XBSYSAPI EXPORTNUM(199) xboxkrnl::NTSTATUS NTAPI xboxkrnl::NtFreeVirtualMemory ( IN OUT PVOID *BaseAddress, IN OUT PULONG FreeSize, @@ -1529,7 +1529,7 @@ XBSYSAPI EXPORTNUM(199) NTSTATUS NTAPI xboxkrnl::NtFreeVirtualMemory // ****************************************************************** // * 0x00CA - NtOpenFile // ****************************************************************** -XBSYSAPI EXPORTNUM(202) NTSTATUS NTAPI xboxkrnl::NtOpenFile +XBSYSAPI EXPORTNUM(202) xboxkrnl::NTSTATUS NTAPI xboxkrnl::NtOpenFile ( OUT PHANDLE FileHandle, IN ACCESS_MASK DesiredAccess, @@ -1566,7 +1566,7 @@ XBSYSAPI EXPORTNUM(202) NTSTATUS NTAPI xboxkrnl::NtOpenFile // ****************************************************************** // * 0x00CF - NtQueryDirectoryFile // ****************************************************************** -XBSYSAPI EXPORTNUM(207) NTSTATUS NTAPI xboxkrnl::NtQueryDirectoryFile +XBSYSAPI EXPORTNUM(207) xboxkrnl::NTSTATUS NTAPI xboxkrnl::NtQueryDirectoryFile ( IN HANDLE FileHandle, IN HANDLE Event OPTIONAL, @@ -1658,7 +1658,7 @@ XBSYSAPI EXPORTNUM(207) NTSTATUS NTAPI xboxkrnl::NtQueryDirectoryFile // ****************************************************************** // * 0x00D2 - NtQueryFullAttributesFile // ****************************************************************** -XBSYSAPI EXPORTNUM(210) NTSTATUS NTAPI xboxkrnl::NtQueryFullAttributesFile +XBSYSAPI EXPORTNUM(210) xboxkrnl::NTSTATUS NTAPI xboxkrnl::NtQueryFullAttributesFile ( IN POBJECT_ATTRIBUTES ObjectAttributes, OUT PVOID Attributes @@ -1699,7 +1699,7 @@ XBSYSAPI EXPORTNUM(210) NTSTATUS NTAPI xboxkrnl::NtQueryFullAttributesFile // ****************************************************************** // * 0x00D3 - NtQueryInformationFile // ****************************************************************** -XBSYSAPI EXPORTNUM(211) NTSTATUS NTAPI xboxkrnl::NtQueryInformationFile +XBSYSAPI EXPORTNUM(211) xboxkrnl::NTSTATUS NTAPI xboxkrnl::NtQueryInformationFile ( IN HANDLE FileHandle, OUT PIO_STATUS_BLOCK IoStatusBlock, @@ -1765,7 +1765,7 @@ XBSYSAPI EXPORTNUM(211) NTSTATUS NTAPI xboxkrnl::NtQueryInformationFile // ****************************************************************** // * 0x00DA - NtQueryVolumeInformationFile // ****************************************************************** -XBSYSAPI EXPORTNUM(218) NTSTATUS NTAPI xboxkrnl::NtQueryVolumeInformationFile +XBSYSAPI EXPORTNUM(218) xboxkrnl::NTSTATUS NTAPI xboxkrnl::NtQueryVolumeInformationFile ( IN HANDLE FileHandle, OUT PIO_STATUS_BLOCK IoStatusBlock, @@ -1818,7 +1818,7 @@ XBSYSAPI EXPORTNUM(218) NTSTATUS NTAPI xboxkrnl::NtQueryVolumeInformationFile // ****************************************************************** // * 0x00DA - NtReadFile // ****************************************************************** -XBSYSAPI EXPORTNUM(219) NTSTATUS NTAPI xboxkrnl::NtReadFile +XBSYSAPI EXPORTNUM(219) xboxkrnl::NTSTATUS NTAPI xboxkrnl::NtReadFile ( IN HANDLE FileHandle, // TODO: correct paramters IN HANDLE Event OPTIONAL, @@ -1863,7 +1863,7 @@ XBSYSAPI EXPORTNUM(219) NTSTATUS NTAPI xboxkrnl::NtReadFile // ****************************************************************** // * 0x00DD - NtReleaseMutant // ****************************************************************** -XBSYSAPI EXPORTNUM(221) NTSTATUS NTAPI xboxkrnl::NtReleaseMutant +XBSYSAPI EXPORTNUM(221) xboxkrnl::NTSTATUS NTAPI xboxkrnl::NtReleaseMutant ( IN HANDLE MutantHandle, OUT PLONG PreviousCount @@ -1892,7 +1892,7 @@ XBSYSAPI EXPORTNUM(221) NTSTATUS NTAPI xboxkrnl::NtReleaseMutant // ****************************************************************** // * 0x00E0 - NtResumeThread // ****************************************************************** -XBSYSAPI EXPORTNUM(224) NTSTATUS NTAPI xboxkrnl::NtResumeThread +XBSYSAPI EXPORTNUM(224) xboxkrnl::NTSTATUS NTAPI xboxkrnl::NtResumeThread ( IN HANDLE ThreadHandle, OUT PULONG PreviousSuspendCount @@ -1919,7 +1919,7 @@ XBSYSAPI EXPORTNUM(224) NTSTATUS NTAPI xboxkrnl::NtResumeThread // ****************************************************************** // * 0x00E1 - NtSetEvent // ****************************************************************** -XBSYSAPI EXPORTNUM(225) NTSTATUS NTAPI xboxkrnl::NtSetEvent +XBSYSAPI EXPORTNUM(225) xboxkrnl::NTSTATUS NTAPI xboxkrnl::NtSetEvent ( IN HANDLE EventHandle, OUT PLONG PreviousState @@ -1947,7 +1947,7 @@ XBSYSAPI EXPORTNUM(225) NTSTATUS NTAPI xboxkrnl::NtSetEvent // ****************************************************************** // * 0x00E2 - NtSetInformationFile // ****************************************************************** -XBSYSAPI EXPORTNUM(226) NTSTATUS NTAPI xboxkrnl::NtSetInformationFile +XBSYSAPI EXPORTNUM(226) xboxkrnl::NTSTATUS NTAPI xboxkrnl::NtSetInformationFile ( IN HANDLE FileHandle, // TODO: correct paramters OUT PVOID IoStatusBlock, @@ -1979,7 +1979,7 @@ XBSYSAPI EXPORTNUM(226) NTSTATUS NTAPI xboxkrnl::NtSetInformationFile // ****************************************************************** // * 0x00E7 - NtSuspendThread // ****************************************************************** -XBSYSAPI EXPORTNUM(231) NTSTATUS NTAPI xboxkrnl::NtSuspendThread +XBSYSAPI EXPORTNUM(231) xboxkrnl::NTSTATUS NTAPI xboxkrnl::NtSuspendThread ( IN HANDLE ThreadHandle, OUT PULONG PreviousSuspendCount OPTIONAL @@ -2090,7 +2090,7 @@ XBSYSAPI EXPORTNUM(232) VOID NTAPI xboxkrnl::NtUserIoApcDispatcher // ****************************************************************** // * 0x00EA - NtWaitForSingleObjectEx // ****************************************************************** -XBSYSAPI EXPORTNUM(234) NTSTATUS NTAPI xboxkrnl::NtWaitForSingleObjectEx +XBSYSAPI EXPORTNUM(234) xboxkrnl::NTSTATUS NTAPI xboxkrnl::NtWaitForSingleObjectEx ( IN HANDLE Handle, IN CHAR WaitMode, @@ -2121,7 +2121,7 @@ XBSYSAPI EXPORTNUM(234) NTSTATUS NTAPI xboxkrnl::NtWaitForSingleObjectEx // ****************************************************************** // * NtWaitForMultipleObjectsEx // ****************************************************************** -XBSYSAPI EXPORTNUM(235) NTSTATUS NTAPI xboxkrnl::NtWaitForMultipleObjectsEx +XBSYSAPI EXPORTNUM(235) xboxkrnl::NTSTATUS NTAPI xboxkrnl::NtWaitForMultipleObjectsEx ( IN ULONG Count, IN HANDLE *Handles, @@ -2155,7 +2155,7 @@ XBSYSAPI EXPORTNUM(235) NTSTATUS NTAPI xboxkrnl::NtWaitForMultipleObjectsEx // ****************************************************************** // * 0x00EC - NtWriteFile // ****************************************************************** -XBSYSAPI EXPORTNUM(236) NTSTATUS NTAPI xboxkrnl::NtWriteFile +XBSYSAPI EXPORTNUM(236) xboxkrnl::NTSTATUS NTAPI xboxkrnl::NtWriteFile ( IN HANDLE FileHandle, // TODO: correct paramters IN PVOID Event, @@ -2217,7 +2217,7 @@ XBSYSAPI EXPORTNUM(238) VOID NTAPI xboxkrnl::NtYieldExecution() // ****************************************************************** // * 0x00FF - PsCreateSystemThreadEx // ****************************************************************** -XBSYSAPI EXPORTNUM(255) NTSTATUS NTAPI xboxkrnl::PsCreateSystemThreadEx +XBSYSAPI EXPORTNUM(255) xboxkrnl::NTSTATUS NTAPI xboxkrnl::PsCreateSystemThreadEx ( OUT PHANDLE ThreadHandle, IN ULONG ThreadExtraSize, @@ -2326,7 +2326,7 @@ XBSYSAPI EXPORTNUM(258) VOID NTAPI xboxkrnl::PsTerminateSystemThread(IN NTSTATUS // ****************************************************************** // * 0x0104 - RtlAnsiStringToUnicodeString // ****************************************************************** -XBSYSAPI EXPORTNUM(260) NTSTATUS NTAPI xboxkrnl::RtlAnsiStringToUnicodeString +XBSYSAPI EXPORTNUM(260) xboxkrnl::NTSTATUS NTAPI xboxkrnl::RtlAnsiStringToUnicodeString ( PUNICODE_STRING DestinationString, PSTRING SourceString, diff --git a/src/CxbxKrnl/EmuLDT.cpp b/src/CxbxKrnl/EmuLDT.cpp index 69b96c028..a5c358010 100644 --- a/src/CxbxKrnl/EmuLDT.cpp +++ b/src/CxbxKrnl/EmuLDT.cpp @@ -127,8 +127,6 @@ uint16 EmuAllocateLDT(uint32 dwBaseAddr, uint32 dwLimit) // * Allocate selector // ****************************************************************** { - using namespace NtDll; - if(!NT_SUCCESS(NtDll::NtSetLdtEntries((x*8)+7+8, LDTEntry, 0, LDTEntry))) { LeaveCriticalSection(&EmuLDTLock); diff --git a/src/CxbxKrnl/EmuXOnline.cpp b/src/CxbxKrnl/EmuXOnline.cpp index b247d6150..78596279e 100644 --- a/src/CxbxKrnl/EmuXOnline.cpp +++ b/src/CxbxKrnl/EmuXOnline.cpp @@ -65,7 +65,7 @@ int WINAPI XTL::EmuWSAStartup ");\n", GetCurrentThreadId(), wVersionRequested, lpWSAData); - int ret = XTL::WSAStartup(wVersionRequested, lpWSAData); + int ret = WSAStartup(wVersionRequested, lpWSAData); EmuSwapFS(); // XBox FS diff --git a/src/CxbxKrnl/EmuXOnline.h b/src/CxbxKrnl/EmuXOnline.h index 2c2608cf9..fe17b96f2 100644 --- a/src/CxbxKrnl/EmuXOnline.h +++ b/src/CxbxKrnl/EmuXOnline.h @@ -34,21 +34,6 @@ #ifndef EMUXONLINE_H #define EMUXONLINE_H -// If you've never seen ugly code before, here is some for you -#undef FD_SET -#undef SO_DONTLINGER -#undef AF_IPX -#undef AF_MAX -#undef SOMAXCONN -#undef FD_READ -#undef FD_WRITE -#undef FD_OOB -#undef FD_ACCEPT -#undef FD_CONNECT -#undef FD_CLOSE - -#include
- // ****************************************************************** // * clas: EmuThis // ******************************************************************