[core,gateway] annotate DeadStore warnings

This commit is contained in:
akallabeth 2024-09-30 20:14:42 +02:00
parent a1a8846ad2
commit ae61278d18
No known key found for this signature in database
GPG Key ID: A49454A3FC909FD5
2 changed files with 4 additions and 0 deletions

View File

@ -63,6 +63,7 @@ static const char* PTYPE_STRINGS[] = { "PTYPE_REQUEST", "PTYPE_PING",
static const char* client_in_state_str(CLIENT_IN_CHANNEL_STATE state)
{
// NOLINTNEXTLINE(clang-analyzer-deadcode.DeadStores)
const char* str = "CLIENT_IN_CHANNEL_STATE_UNKNOWN";
switch (state)
@ -102,6 +103,7 @@ static const char* client_in_state_str(CLIENT_IN_CHANNEL_STATE state)
static const char* client_out_state_str(CLIENT_OUT_CHANNEL_STATE state)
{
// NOLINTNEXTLINE(clang-analyzer-deadcode.DeadStores)
const char* str = "CLIENT_OUT_CHANNEL_STATE_UNKNOWN";
switch (state)
@ -153,6 +155,7 @@ static const char* client_out_state_str(CLIENT_OUT_CHANNEL_STATE state)
const char* rpc_vc_state_str(VIRTUAL_CONNECTION_STATE state)
{
// NOLINTNEXTLINE(clang-analyzer-deadcode.DeadStores)
const char* str = "VIRTUAL_CONNECTION_STATE_UNKNOWN";
switch (state)

View File

@ -45,6 +45,7 @@
static const char* rpc_client_state_str(RPC_CLIENT_STATE state)
{
// NOLINTNEXTLINE(clang-analyzer-deadcode.DeadStores)
const char* str = "RPC_CLIENT_STATE_UNKNOWN";
switch (state)