From 780b22a31df7ead062805932f8c7f46d9e47a436 Mon Sep 17 00:00:00 2001 From: Brad King <brad.king@kitware.com> Date: Thu, 12 Feb 2004 13:38:18 -0500 Subject: [PATCH] ERR: Fixed use of _findfirst for MSVC 6. --- Directory.cxx | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Directory.cxx b/Directory.cxx index add296b..40b29f0 100644 --- a/Directory.cxx +++ b/Directory.cxx @@ -81,6 +81,11 @@ namespace KWSYS_NAMESPACE bool Directory::Load(const char* name) { +#if _MSC_VER < 1300 + long srchHandle; +#else + intptr_t srchHandle; +#endif char* buf; size_t n = strlen(name); if ( name[n - 1] == '/' ) @@ -96,7 +101,7 @@ bool Directory::Load(const char* name) struct _finddata_t data; // data of current file // Now put them into the file array - intptr_t srchHandle = _findfirst(buf, &data); + srchHandle = _findfirst(buf, &data); delete [] buf; if ( srchHandle == -1 ) -- GitLab