libstdc++: Re-enable workaround for _wstat64 bug [PR 88881]
authorJonathan Wakely <jwakely@redhat.com>
Wed, 10 Feb 2021 16:51:34 +0000 (16:51 +0000)
committerJonathan Wakely <jwakely@redhat.com>
Wed, 10 Feb 2021 16:51:34 +0000 (16:51 +0000)
This wasn't fixed upstream for mingw-w64 so we still need the
workaround.

libstdc++-v3/ChangeLog:

PR libstdc++/88881
* src/c++17/fs_ops.cc (fs::status): Re-enable workaround.

libstdc++-v3/src/c++17/fs_ops.cc

index 7deb4c33447d12bc81dc40ca5f3730ed04f05ee5..3817655471c5cadb783fa3809eaa392ec1d8bb0c 100644 (file)
@@ -1462,7 +1462,6 @@ fs::status(const fs::path& p, error_code& ec) noexcept
   auto str = p.c_str();
 
 #if _GLIBCXX_FILESYSTEM_IS_WINDOWS
-#if ! defined __MINGW64_VERSION_MAJOR || __MINGW64_VERSION_MAJOR < 6
   // stat() fails if there's a trailing slash (PR 88881)
   path p2;
   if (p.has_relative_path() && !p.has_filename())
@@ -1479,7 +1478,6 @@ fs::status(const fs::path& p, error_code& ec) noexcept
        }
       str = p2.c_str();
     }
-#endif
 #endif
 
   stat_type st;