]> git.saurik.com Git - wxWidgets.git/blobdiff - src/msw/dir.cpp
don't declare inline function with dllexport declaration, this provokes mingw32 warni...
[wxWidgets.git] / src / msw / dir.cpp
index 79635bd446e01c059d2ebc64f3bdacb9a3a3b976..bfca51b3225427bc91c2c21c8cc9d7583c53d243 100644 (file)
@@ -184,7 +184,10 @@ bool wxDirData::Read(wxString *filename)
         {
             filespec += _T('\\');
         }
-        filespec += (!m_filespec ? _T("*.*") : m_filespec.c_str());
+        if ( !m_filespec )
+            filespec += _T("*.*");
+        else
+            filespec += m_filespec;
 
         m_finddata = FindFirst(filespec, PTR_TO_FINDDATA);
 
@@ -196,7 +199,7 @@ bool wxDirData::Read(wxString *filename)
 #ifdef __WIN32__
         DWORD err = ::GetLastError();
 
-        if ( err != ERROR_FILE_NOT_FOUND )
+        if ( err != ERROR_FILE_NOT_FOUND && err != ERROR_NO_MORE_FILES )
         {
             wxLogSysError(err, _("Can not enumerate files in directory '%s'"),
                           m_dirname.c_str());
@@ -374,9 +377,15 @@ extern bool
 wxGetDirectoryTimes(const wxString& dirname,
                     FILETIME *ftAccess, FILETIME *ftCreate, FILETIME *ftMod)
 {
+#ifdef __WXWINCE__
+    // FindFirst() is going to fail
+    wxASSERT_MSG( !dirname.empty(),
+                  _T("incorrect directory name format in wxGetDirectoryTimes") );
+#else
     // FindFirst() is going to fail
     wxASSERT_MSG( !dirname.empty() && dirname.Last() != _T('\\'),
                   _T("incorrect directory name format in wxGetDirectoryTimes") );
+#endif
 
     FIND_STRUCT fs;
     FIND_DATA fd = FindFirst(dirname, &fs);