Skip to content

Commit

Permalink
fix: clang analyzer unknown pragma warning
Browse files Browse the repository at this point in the history
  • Loading branch information
Lapshin committed Jun 10, 2024
1 parent b527203 commit 6bb5a5b
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion mqtt_client.c
Original file line number Diff line number Diff line change
Expand Up @@ -945,8 +945,12 @@ esp_err_t esp_mqtt_client_set_uri(esp_mqtt_client_handle_t client, const char *u
MQTT_API_LOCK(client);
// set uri overrides actual scheme, host, path if configured previously
// False-positive leak detection. TODO: GCC-366
#pragma GCC diagnostic push
#pragma GCC diagnostic push // TODO: IDF-10105
#if __clang__
#pragma clang diagnostic ignored "-Wunknown-warning-option"
#else
#pragma GCC diagnostic ignored "-Wpragmas"
#endif
#pragma GCC diagnostic ignored "-Wanalyzer-malloc-leak"
free(client->config->scheme);
free(client->config->host);
Expand Down

0 comments on commit 6bb5a5b

Please sign in to comment.