X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/0e7fa78358f89bdfd0f4b78099543b4beb2faaf6..80c82e01758cd838aa5c922b848454277b11da26:/src/mac/dirmac.cpp diff --git a/src/mac/dirmac.cpp b/src/mac/dirmac.cpp index 9c8f191681..0ccaf0b8e9 100644 --- a/src/mac/dirmac.cpp +++ b/src/mac/dirmac.cpp @@ -119,6 +119,7 @@ wxDirData::wxDirData(const wxString& dirname) m_index = 0 ; OSErr err = FSpGetDirectoryID( &fsspec , &m_dirId , &m_isDir ) ; + wxASSERT_MSG( err == noErr , "Error accessing directory") ; } wxDirData::~wxDirData() @@ -156,6 +157,11 @@ bool wxDirData::Read(wxString *filename) strcpy( (char *)m_name, c_name); #else p2cstr( m_name ) ; +#endif +#if TARGET_CARBON + // under X thats the way the mounting points look like + if ( ( m_CPB.dirInfo.ioDrDirID == 0 ) && ( m_flags & wxDIR_DIRS) ) + break ; #endif if ( ( m_CPB.dirInfo.ioFlAttrib & ioDirMask) != 0 && (m_flags & wxDIR_DIRS) ) // we have a directory break ;