810ab10
diff --git a/util/status.cc b/util/status.cc
810ab10
index ad948f0..9a310c9 100644
810ab10
--- a/util/status.cc
810ab10
+++ b/util/status.cc
810ab10
@@ -32,8 +32,11 @@ const char* Status::CopyState(const char* state) {
810ab10
   assert(ret == 0);
810ab10
   return result;
810ab10
 #else
810ab10
+#pragma GCC diagnostic push
810ab10
+#pragma GCC diagnostic ignored "-Wstringop-overflow="
810ab10
   const size_t cch = std::strlen(state) + 1;  // +1 for the null terminator
810ab10
   return std::strncpy(new char[cch], state, cch);
810ab10
+#pragma GCC diagnostic pop
810ab10
 #endif
810ab10
 }