Blame SOURCES/0005-Disable-tests-for-PR-libstdc-79820-and-PR-libstdc-81.patch

e60d6e
From 3ede89bd19328c26bcd881b873cf4a766ae0da3a Mon Sep 17 00:00:00 2001
e60d6e
From: David Malcolm <dmalcolm@redhat.com>
e60d6e
Date: Wed, 25 Aug 2021 17:04:02 -0400
e60d6e
Subject: [PATCH 05/17] Disable tests for PR libstdc++/79820 and PR
e60d6e
 libstdc++/81751 under DTS
e60d6e
e60d6e
Upstream commit 2017-08-09
e60d6e
  PR libstdc++/81751 don't call fflush(NULL)
e60d6e
    https://gcc.gnu.org/git/?p=gcc.git;a=commitdiff;h=04d07b61cb80fd97e98eb39451ff6a8675a63d90
e60d6e
added these test cases as part of verifying the behavior of sys_open (that
e60d6e
it resets errno and doesn't call fflush on NULL).
e60d6e
e60d6e
These symbols are in the system stdlib when run from DTS and thus aren't
e60d6e
fixed by the above change:
e60d6e
e60d6e
 1521: 000000000007c430    104 FUNC    GLOBAL DEFAULT       12 std::__basic_file<char>::sys_open(int, std::_Ios_Openmode)@@GLIBCXX_3.4
e60d6e
 2895: 000000000007c730     95 FUNC    GLOBAL DEFAULT       12 std::__basic_file<char>::sys_open(_IO_FILE*, std::_Ios_Openmode)@@GLIBCXX_3.4
e60d6e
e60d6e
This patch disables the non-fixed assertions.
e60d6e
---
e60d6e
 libstdc++-v3/testsuite/ext/stdio_filebuf/char/79820.cc | 2 --
e60d6e
 libstdc++-v3/testsuite/ext/stdio_filebuf/char/81751.cc | 1 -
e60d6e
 2 files changed, 3 deletions(-)
e60d6e
e60d6e
diff --git a/libstdc++-v3/testsuite/ext/stdio_filebuf/char/79820.cc b/libstdc++-v3/testsuite/ext/stdio_filebuf/char/79820.cc
e60d6e
index 278b99169..e2a8e3b3d 100644
e60d6e
--- a/libstdc++-v3/testsuite/ext/stdio_filebuf/char/79820.cc
e60d6e
+++ b/libstdc++-v3/testsuite/ext/stdio_filebuf/char/79820.cc
e60d6e
@@ -26,9 +26,7 @@ void
e60d6e
 test01()
e60d6e
 {
e60d6e
   FILE* f = std::fopen("79820.txt", "w");
e60d6e
-  errno = 127;
e60d6e
   __gnu_cxx::stdio_filebuf<char> b(f, std::ios::out, BUFSIZ);
e60d6e
-  VERIFY(errno == 127); // PR libstdc++/79820
e60d6e
   b.close();
e60d6e
   std::fclose(f);
e60d6e
 }
e60d6e
diff --git a/libstdc++-v3/testsuite/ext/stdio_filebuf/char/81751.cc b/libstdc++-v3/testsuite/ext/stdio_filebuf/char/81751.cc
e60d6e
index 21aa06f78..6a231d7cf 100644
e60d6e
--- a/libstdc++-v3/testsuite/ext/stdio_filebuf/char/81751.cc
e60d6e
+++ b/libstdc++-v3/testsuite/ext/stdio_filebuf/char/81751.cc
e60d6e
@@ -31,7 +31,6 @@ test01()
e60d6e
   FILE* in1 = std::fopen("81751.txt", "r");
e60d6e
   __gnu_cxx::stdio_filebuf<char> buf1(in1, std::ios::in, BUFSIZ);
e60d6e
   int c = buf1.sgetc();
e60d6e
-  VERIFY( c == std::char_traits<char>::eof() ); // PR libstdc++/81751
e60d6e
 
e60d6e
   std::fflush(out);
e60d6e
   FILE* in2 = std::fopen("81751.txt", "r");
e60d6e
-- 
e60d6e
2.31.1
e60d6e