lmi-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[lmi-commits] [lmi] master e8ce676c: Sidestep another libstc++ defect


From: Greg Chicares
Subject: [lmi-commits] [lmi] master e8ce676c: Sidestep another libstc++ defect
Date: Thu, 18 Aug 2022 11:26:04 -0400 (EDT)

branch: master
commit e8ce676c1d19dbc81660f7b4b1818a631b49984d
Author: Gregory W. Chicares <gchicares@sbcglobal.net>
Commit: Gregory W. Chicares <gchicares@sbcglobal.net>

    Sidestep another libstc++ defect
---
 istream_to_string_test.cpp | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/istream_to_string_test.cpp b/istream_to_string_test.cpp
index 873d5774..329a2652 100644
--- a/istream_to_string_test.cpp
+++ b/istream_to_string_test.cpp
@@ -40,7 +40,15 @@ void istream_to_string_1
 {
     typedef std::basic_string<Char_t,Traits,Allocator> string_type;
     typedef std::istreambuf_iterator<Char_t,Traits> bisbi;
+    // https://gcc.gnu.org/bugzilla/show_bug.cgi?id=105580
+#if defined LMI_GCC
+#   pragma GCC diagnostic push
+#   pragma GCC diagnostic ignored "-Wnull-dereference"
+#endif // defined LMI_GCC
     string_type((bisbi(is)), bisbi()).swap(s);
+#if defined LMI_GCC
+#   pragma GCC diagnostic pop
+#endif // defined LMI_GCC
     if(!is)
         {
         throw std::runtime_error("Unable to read stream into string.");



reply via email to

[Prev in Thread] Current Thread [Next in Thread]