replaced use of _MAX_PATH with CCHMAXPATH in os/2 code, it now compiles without HAVE_LIBC
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74
diff --git a/include/SDL_config_os2.h b/include/SDL_config_os2.h
index d35bf6d..d332332 100644
--- a/include/SDL_config_os2.h
+++ b/include/SDL_config_os2.h
@@ -61,19 +61,20 @@
#define HAVE_LIBC 1
+#define HAVE_STDARG_H 1
+#define HAVE_STDDEF_H 1
+#define HAVE_STDINT_H 1
+
#define HAVE_SYS_TYPES_H 1
#define HAVE_STDIO_H 1
#define STDC_HEADERS 1
#define HAVE_STDLIB_H 1
-#define HAVE_STDARG_H 1
-#define HAVE_STDDEF_H 1
#define HAVE_MALLOC_H 1
#define HAVE_MEMORY_H 1
#define HAVE_STRING_H 1
#define HAVE_STRINGS_H 1
#define HAVE_WCHAR_H 1
#define HAVE_INTTYPES_H 1
-#define HAVE_STDINT_H 1
#define HAVE_LIMITS_H 1
#define HAVE_CTYPE_H 1
#define HAVE_MATH_H 1
diff --git a/src/filesystem/os2/SDL_sysfilesystem.c b/src/filesystem/os2/SDL_sysfilesystem.c
index 86b6a40..30c7f41 100644
--- a/src/filesystem/os2/SDL_sysfilesystem.c
+++ b/src/filesystem/os2/SDL_sysfilesystem.c
@@ -25,9 +25,9 @@
/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
/* System dependent filesystem routines */
+#include "../../core/os2/SDL_os2.h"
#include "SDL_error.h"
#include "SDL_filesystem.h"
-#include "../../core/os2/SDL_os2.h"
#define INCL_DOSFILEMGR
#define INCL_DOSPROCESS
@@ -43,7 +43,7 @@ SDL_GetBasePath(void)
ULONG ulRC = DosGetInfoBlocks(&tib, &pib);
PCHAR pcEnd;
ULONG cbResult;
- CHAR acBuf[_MAX_PATH];
+ CHAR acBuf[CCHMAXPATH];
if (ulRC != NO_ERROR) {
debug_os2("DosGetInfoBlocks() failed, rc = %u", ulRC);
@@ -73,7 +73,7 @@ char *
SDL_GetPrefPath(const char *org, const char *app)
{
PSZ pszPath;
- CHAR acBuf[_MAX_PATH];
+ CHAR acBuf[CCHMAXPATH];
int lPosApp, lPosOrg;
PSZ pszApp, pszOrg;
diff --git a/src/video/os2/SDL_os2video.c b/src/video/os2/SDL_os2video.c
index 3c952b5..b0937ff 100644
--- a/src/video/os2/SDL_os2video.c
+++ b/src/video/os2/SDL_os2video.c
@@ -394,7 +394,7 @@ static MRESULT _wmDrop(WINDATA *pWinData, PDRAGINFO pDragInfo)
{
ULONG ulIdx;
PDRAGITEM pDragItem;
- CHAR acFName[_MAX_PATH];
+ CHAR acFName[CCHMAXPATH];
PCHAR pcFName;
if (!DrgAccessDraginfo(pDragInfo))