summaryrefslogtreecommitdiff
path: root/libiberty/regex.c
diff options
context:
space:
mode:
Diffstat (limited to 'libiberty/regex.c')
-rw-r--r--libiberty/regex.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/libiberty/regex.c b/libiberty/regex.c
index cc5a4605ced..84af5276ae8 100644
--- a/libiberty/regex.c
+++ b/libiberty/regex.c
@@ -30,6 +30,10 @@
#pragma alloca
#endif
+#if __GNUC__ >= 12
+# pragma GCC diagnostic ignored "-Wuse-after-free"
+#endif
+
#undef _GNU_SOURCE
#define _GNU_SOURCE