This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
[patch] Fix build failure with MinGW
- From: Eric Botcazou <ebotcazou at adacore dot com>
- To: libstdc++ at gcc dot gnu dot org
- Cc: gcc-patches at gcc dot gnu dot org
- Date: Sat, 30 Mar 2019 12:56:48 +0100
- Subject: [patch] Fix build failure with MinGW
Tested on x86_64-pc-mingw32, OK for the mainline?
2019-03-30 Eric Botcazou <ebotcazou@adacore.com>
* src/c++17/fs_ops.cc (fs::permissions): Use std::errc::not_supported.
--
Eric Botcazou
diff --git libstdc++-v3/src/c++17/fs_ops.cc libstdc++-v3/src/c++17/fs_ops.cc
index 3ff0ded1c66..5ca523826cb 100644
--- libstdc++-v3/src/c++17/fs_ops.cc
+++ libstdc++-v3/src/c++17/fs_ops.cc
@@ -1127,7 +1127,7 @@ fs::permissions(const path& p, perms prms, perm_options opts,
err = errno;
#else
if (nofollow && is_symlink(st))
- ec = std::make_error_code(std::errc::operation_not_supported);
+ ec = std::make_error_code(std::errc::not_supported);
else if (posix::chmod(p.c_str(), static_cast<mode_t>(prms)))
err = errno;
#endif