From e157fcfe37df8dd1157f0cc8674174619072af23 Mon Sep 17 00:00:00 2001 From: Andy Green Date: Mon, 19 Mar 2018 08:25:02 +0800 Subject: [PATCH] coverity 188316: hide supposed dead code from coverity with NO_EXTENSIONS --- lib/client/client-parser.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/lib/client/client-parser.c b/lib/client/client-parser.c index bc391cba..bd550377 100644 --- a/lib/client/client-parser.c +++ b/lib/client/client-parser.c @@ -555,7 +555,12 @@ utf8_fail: if (callback_action == LWS_CALLBACK_CLIENT_RECEIVE_PONG) lwsl_info("Client doing pong callback\n"); - if (n && eff_buf.token_len) + if ( + /* coverity says dead code otherwise */ +#if !defined(LWS_NO_EXTENSIONS) + n && +#endif + eff_buf.token_len) /* extension had more... main loop will come back * we want callback to be done with this set, if so, * because lws_is_final() hides it was final until the