mirror of
https://github.com/Kitware/CMake.git
synced 2026-04-21 05:38:24 -05:00
KWSys SystemTools: Port cygwin path conversion to modern API
The cygwin_conv_to_win32_path function is deprecated in favor of cygwin_conv_path. Use the latter.
This commit is contained in:
@@ -92,7 +92,7 @@ extern char **environ;
|
||||
#endif
|
||||
|
||||
#ifdef __CYGWIN__
|
||||
extern "C" void cygwin_conv_to_win32_path(const char *path, char *win32_path);
|
||||
# include <sys/cygwin.h>
|
||||
#endif
|
||||
|
||||
// getpwnam doesn't exist on Windows and Cray Xt3/Catamount
|
||||
@@ -1110,7 +1110,10 @@ bool SystemTools::PathCygwinToWin32(const char *path, char *win32_path)
|
||||
}
|
||||
else
|
||||
{
|
||||
cygwin_conv_to_win32_path(path, win32_path);
|
||||
if(cygwin_conv_path(CCP_POSIX_TO_WIN_A, path, win32_path, MAX_PATH) != 0)
|
||||
{
|
||||
win32_path[0] = 0;
|
||||
}
|
||||
SystemToolsTranslationMap::value_type entry(path, win32_path);
|
||||
SystemTools::Cyg2Win32Map->insert(entry);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user