From cd512217e570f796ef3e3a7ad67c66d78c83c2dc Mon Sep 17 00:00:00 2001 From: Guy Harris Date: Fri, 26 Oct 2018 13:02:59 -0700 Subject: [PATCH 214/470] Make qerr const. It's not something we're allowed to modify, as that could fail if two or more threads are all running in pcap_compile(); declare it as const to make sure we don't modify it. --- grammar.y | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/grammar.y b/grammar.y index e060cde..3eeb135 100644 --- a/grammar.y +++ b/grammar.y @@ -237,7 +237,7 @@ str2tok(const char *str, const struct tok *toks) return (-1); } -static struct qual qerr = { Q_UNDEF, Q_UNDEF, Q_UNDEF, Q_UNDEF }; +static const struct qual qerr = { Q_UNDEF, Q_UNDEF, Q_UNDEF, Q_UNDEF }; static PCAP_NORETURN_DEF void yyerror(void *yyscanner _U_, compiler_state_t *cstate, const char *msg) -- 1.8.3.1