mirror of
https://github.com/espressif/esp-idf.git
synced 2024-10-05 20:47:46 -04:00
esp_local_ctrl: remove "Wno-format" cflag and fix formatting errors
This commit is contained in:
parent
035c2e5799
commit
b709c84e1c
@ -24,5 +24,3 @@ idf_component_register(SRCS "${srcs}"
|
||||
PRIV_REQUIRES protobuf-c)
|
||||
|
||||
idf_component_optional_requires(PRIVATE espressif__mdns mdns)
|
||||
|
||||
target_compile_options(${COMPONENT_LIB} PRIVATE "-Wno-format")
|
||||
|
@ -6,6 +6,7 @@
|
||||
|
||||
#include <stdio.h>
|
||||
#include <string.h>
|
||||
#include <inttypes.h>
|
||||
#include <esp_err.h>
|
||||
#include <esp_log.h>
|
||||
|
||||
@ -355,7 +356,7 @@ esp_err_t esp_local_ctrl_get_prop_values(size_t total_indices, uint32_t *indices
|
||||
/* Convert indices to names */
|
||||
for (size_t i = 0; i < total_indices; i++) {
|
||||
if (indices[i] >= local_ctrl_inst_ctx->props_count) {
|
||||
ESP_LOGE(TAG, "Invalid property index %d", indices[i]);
|
||||
ESP_LOGE(TAG, "Invalid property index %" PRId32, indices[i]);
|
||||
return ESP_ERR_INVALID_ARG;
|
||||
}
|
||||
props[i].name = local_ctrl_inst_ctx->props[indices[i]]->name;
|
||||
@ -396,7 +397,7 @@ esp_err_t esp_local_ctrl_set_prop_values(size_t total_indices, uint32_t *indices
|
||||
}
|
||||
for (size_t i = 0; i < total_indices; i++) {
|
||||
if (indices[i] >= local_ctrl_inst_ctx->props_count) {
|
||||
ESP_LOGE(TAG, "Invalid property index %d", indices[i]);
|
||||
ESP_LOGE(TAG, "Invalid property index %" PRId32, indices[i]);
|
||||
free(props);
|
||||
return ESP_ERR_INVALID_ARG;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user