From d2cf8765aaef9271693e68ecbf26b2ddb2c24d7c Mon Sep 17 00:00:00 2001 From: Joel Rosdahl Date: Wed, 27 Jul 2016 11:22:12 +0200 Subject: Bail out on -P at end of -Wp, as well --- ccache.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'ccache.h') diff --git a/ccache.h b/ccache.h index 3081d34e..7ab03212 100644 --- a/ccache.h +++ b/ccache.h @@ -69,7 +69,11 @@ enum stats { #define SLOPPY_NO_SYSTEM_HEADERS 64 #define str_eq(s1, s2) (strcmp((s1), (s2)) == 0) -#define str_startswith(s, p) (strncmp((s), (p), strlen((p))) == 0) +#define str_startswith(s, prefix) \ + (strncmp((s), (prefix), strlen((prefix))) == 0) +#define str_endswith(s, suffix) \ + (strlen(s) >= strlen(suffix) \ + && str_eq((s) + strlen(s) - strlen(suffix), (suffix))) // ---------------------------------------------------------------------------- // args.c -- cgit v1.2.1