summaryrefslogtreecommitdiffstats
path: root/compat
diff options
context:
space:
mode:
authorPatrick Steinhardt <ps@pks.im>2024-12-06 11:27:17 +0100
committerJunio C Hamano <gitster@pobox.com>2024-12-06 12:20:01 +0100
commit6e1d0ce47014f2d8434c54ef70dc9b43602652a5 (patch)
tree6170faf597a5140aeda91725d205c930bbd0b416 /compat
parentgit-compat-util: introduce macros to disable "-Wsign-compare" warnings (diff)
downloadgit-6e1d0ce47014f2d8434c54ef70dc9b43602652a5.tar.xz
git-6e1d0ce47014f2d8434c54ef70dc9b43602652a5.zip
compat/regex: explicitly ignore "-Wsign-compare" warnings
Explicitly ignore "-Wsign-compare" warnings in our bundled copy of the regcomp implementation. We don't use the macro introduced in the preceding commit because this code does not include "git-compat-util.h" in the first place. Note that we already directly use "#pragma GCC diagnostic ignored" in "regcomp.c", so it shouldn't be an issue to use it directly in the new spot, either. Signed-off-by: Patrick Steinhardt <ps@pks.im> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'compat')
-rw-r--r--compat/regex/regex.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/compat/regex/regex.c b/compat/regex/regex.c
index e6f4a5d177..4b09cc4e14 100644
--- a/compat/regex/regex.c
+++ b/compat/regex/regex.c
@@ -17,6 +17,8 @@
License along with the GNU C Library; if not, see
<http://www.gnu.org/licenses/>. */
+#pragma GCC diagnostic ignored "-Wsign-compare"
+
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif