Skip to content

Commit

Permalink
Merge branch 'fix/analyzer-unknown-pragma-warning' into 'master'
Browse files Browse the repository at this point in the history
fix: clang analyzer unknown pragma warning

See merge request espressif/esp-mqtt!215
  • Loading branch information
euripedesrocha committed Jun 10, 2024
2 parents e6c5596 + 6bb5a5b commit cac1552
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 cac1552

Please sign in to comment.