1
0
Fork 0
mirror of https://github.com/warmcat/libwebsockets.git synced 2025-03-09 00:00:04 +01:00

coverity: 62134: protect debug-only statement with preprocessor conditional

Compiler has no problem with it but coverity complains nobody uses p in release build
This commit is contained in:
Andy Green 2020-08-18 11:32:44 +01:00
parent 598a82ca1d
commit 398a9e1bad

View file

@ -333,9 +333,11 @@ static void lws_dump_header(struct lws *wsi, int hdr)
strcpy(s, "(too big to show)");
else
s[len] = '\0';
#if defined(_DEBUG)
p = lws_token_to_string(hdr);
lwsl_header(" hdr tok %d (%s) = '%s' (len %d)\n", hdr,
p ? (char *)p : (char *)"null", s, len);
#endif
}
/*