From e4c676a4905c38aa0aa2f7c0d490bf841beee05d Mon Sep 17 00:00:00 2001 From: Angus Leeming Date: Sun, 2 Oct 2005 21:49:52 +0000 Subject: [PATCH] Make things compile on MSVC: There's no , so just use s/PATH_MAX/MAX_PATH/ git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10508 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/support/os_win32.C | 6 ++---- src/support/os_win32.h | 4 ++-- src/support/package.C.in | 4 +--- 3 files changed, 5 insertions(+), 9 deletions(-) diff --git a/src/support/os_win32.C b/src/support/os_win32.C index bb840a9cc3..462f6fe3c4 100644 --- a/src/support/os_win32.C +++ b/src/support/os_win32.C @@ -27,8 +27,6 @@ #include -#include - /* The GetLongPathName macro may be defined on the compiling machine, * but we must use a bit of trickery if the resulting executable is * to run on a Win95 machine. @@ -195,7 +193,7 @@ namespace { string const get_long_path(string const & short_path) { - std::vector long_path(PATH_MAX); + std::vector long_path(MAX_PATH); DWORD result = GetLongPathName(short_path.c_str(), &long_path[0], long_path.size()); @@ -312,7 +310,7 @@ GetFolderPath::~GetFolderPath() // Eg CSIDL_PERSONAL -> "C:/Documents and Settings/USERNAME/My Documents" string const GetFolderPath::operator()(folder_id _id) const { - char folder_path[PATH_MAX]; + char folder_path[MAX_PATH]; int id = 0; switch (_id) { diff --git a/src/support/os_win32.h b/src/support/os_win32.h index 4933a2482e..77af7fb984 100644 --- a/src/support/os_win32.h +++ b/src/support/os_win32.h @@ -29,7 +29,7 @@ * in under MinGW and Cygwin. * It is missing in earlier versions of the MinGW w32api headers. * - * We need to #include now to make available the + * We need to #include now to make available the * DWORD, HMODULE et al. typedefs, so first define WINVER, _WIN32_IE. * * Note: __CYGWIN__ can be defined here if building in _WIN32 mode. @@ -42,7 +42,7 @@ # define _WIN32_IE 0x0500 #endif -#include +#include namespace lyx { diff --git a/src/support/package.C.in b/src/support/package.C.in index d9c2758893..c055ce541f 100644 --- a/src/support/package.C.in +++ b/src/support/package.C.in @@ -40,9 +40,7 @@ #error USE_FOO_PACKAGING must be defined for FOO = WINDOWS, MACOSX or POSIX. #endif -#if defined (USE_WINDOWS_PACKAGING) -# include -#elif defined (USE_MACOSX_PACKAGING) +#if defined (USE_MACOSX_PACKAGING) # include // FSFindFolder, FSRefMakePath #endif -- 2.39.2