From 641459e98668607478017cf4fa0060f2363cf367 Mon Sep 17 00:00:00 2001 From: Thiago Macieira Date: Wed, 30 Aug 2023 12:15:02 -0700 Subject: [PATCH] tst_QFileInfo: don't trigger libstdc++ std::filesystem bug MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit libstdc++'s std::filesystem::path implementation incorrectly assumes that any 8-bit char input is UTF-8, when it patently isn't on Windows. Reported at https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111244 Fixes: QTBUG-116609 Change-Id: I2b24e1d3cad44897906efffd17803f2862935c9b Reviewed-by: Mårten Nordheim (cherry picked from commit 2b06d41b46cf97a92dee10c4432cdc5c719bcee0) Reviewed-by: Qt Cherry-pick Bot --- tests/auto/corelib/io/qfileinfo/tst_qfileinfo.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/tests/auto/corelib/io/qfileinfo/tst_qfileinfo.cpp b/tests/auto/corelib/io/qfileinfo/tst_qfileinfo.cpp index c9db19db224..2e70f3af9a3 100644 --- a/tests/auto/corelib/io/qfileinfo/tst_qfileinfo.cpp +++ b/tests/auto/corelib/io/qfileinfo/tst_qfileinfo.cpp @@ -2322,7 +2322,10 @@ void tst_QFileInfo::stdfilesystem() COMPARE_CONSTRUCTION("/path/TO/file.txt"); COMPARE_CONSTRUCTION("./path/TO/file.txt"); COMPARE_CONSTRUCTION("../file.txt"); +#if !(defined(__GLIBCXX__) && defined(Q_OS_WIN32)) + // libstdc++ bug on Windows - https://gcc.gnu.org/bugzilla/show_bug.cgi?id=111244 COMPARE_CONSTRUCTION("./filæ.txt"); +#endif #undef COMPARE_CONSTRUCTION {