Commit a14ce4c7 authored by Max Kellermann's avatar Max Kellermann

lib/pcre/RegexPointer: work around bogus -Wmaybe-uninitialized with GCC 11

parent 85a5b7de
...@@ -40,6 +40,13 @@ ...@@ -40,6 +40,13 @@
#include <array> #include <array>
#if GCC_CHECK_VERSION(11,0)
#pragma GCC diagnostic push
/* bogus GCC 11 warning "ovector may be used uninitialized" in the
ovector.size() call */
#pragma GCC diagnostic ignored "-Wmaybe-uninitialized"
#endif
class RegexPointer { class RegexPointer {
protected: protected:
pcre *re = nullptr; pcre *re = nullptr;
...@@ -63,4 +70,8 @@ public: ...@@ -63,4 +70,8 @@ public:
} }
}; };
#if GCC_CHECK_VERSION(11,0)
#pragma GCC diagnostic pop
#endif
#endif #endif
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment