mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-01-07 19:57:45 +03:00
LibCore: Use DirectoryEntry::from_stat on Haiku
This commit is contained in:
parent
1d475e9312
commit
cf6781cdee
Notes:
sideshowbarker
2024-07-19 16:51:46 +09:00
Author: https://github.com/ghost Commit: https://github.com/SerenityOS/serenity/commit/cf6781cdee6 Pull-request: https://github.com/SerenityOS/serenity/pull/20808 Reviewed-by: https://github.com/ADKaster Reviewed-by: https://github.com/Hendiadyoin1 Reviewed-by: https://github.com/diversys
@ -56,7 +56,7 @@ bool DirIterator::advance_next()
|
||||
return false;
|
||||
}
|
||||
|
||||
#ifdef AK_OS_SOLARIS
|
||||
#if defined(AK_OS_SOLARIS) || defined(AK_OS_HAIKU)
|
||||
m_next = DirectoryEntry::from_stat(m_dir, *de);
|
||||
#else
|
||||
m_next = DirectoryEntry::from_dirent(*de);
|
||||
|
@ -32,7 +32,7 @@ static DirectoryEntry::Type directory_entry_type_from_stat(mode_t st_mode)
|
||||
VERIFY_NOT_REACHED();
|
||||
}
|
||||
|
||||
#ifndef AK_OS_SOLARIS
|
||||
#if !defined(AK_OS_SOLARIS) && !defined(AK_OS_HAIKU)
|
||||
static DirectoryEntry::Type directory_entry_type_from_posix(unsigned char dt_constant)
|
||||
{
|
||||
switch (dt_constant) {
|
||||
@ -72,7 +72,7 @@ DirectoryEntry DirectoryEntry::from_stat(DIR* d, dirent const& de)
|
||||
};
|
||||
}
|
||||
|
||||
#ifndef AK_OS_SOLARIS
|
||||
#if !defined(AK_OS_SOLARIS) && !defined(AK_OS_HAIKU)
|
||||
DirectoryEntry DirectoryEntry::from_dirent(dirent const& de)
|
||||
{
|
||||
return DirectoryEntry {
|
||||
|
Loading…
Reference in New Issue
Block a user