瀏覽代碼

Merge branch 'bugfix/console-fix-ignored-warnings' into 'master'

console: fix and re-enable no-format warnings

Closes IDF-6791

See merge request espressif/esp-idf!22534
Zim Kalinowski 2 年之前
父節點
當前提交
afbdb0f3ef
共有 2 個文件被更改,包括 1 次插入4 次删除
  1. 0 3
      components/console/CMakeLists.txt
  2. 1 1
      components/console/esp_console_repl.c

+ 0 - 3
components/console/CMakeLists.txt

@@ -22,6 +22,3 @@ idf_component_register(SRCS "commands.c"
                     INCLUDE_DIRS "."
                     INCLUDE_DIRS "."
                     REQUIRES vfs
                     REQUIRES vfs
                     PRIV_REQUIRES driver)
                     PRIV_REQUIRES driver)
-
-
-target_compile_options(${COMPONENT_LIB} PRIVATE "-Wno-format")

+ 1 - 1
components/console/esp_console_repl.c

@@ -355,7 +355,7 @@ static esp_err_t esp_console_setup_history(const char *history_path, uint32_t ma
 
 
     /* Set command history size */
     /* Set command history size */
     if (linenoiseHistorySetMaxLen(max_history_len) != 1) {
     if (linenoiseHistorySetMaxLen(max_history_len) != 1) {
-        ESP_LOGE(TAG, "set max history length to %d failed", max_history_len);
+        ESP_LOGE(TAG, "set max history length to %"PRIu32" failed", max_history_len);
         ret = ESP_FAIL;
         ret = ESP_FAIL;
         goto _exit;
         goto _exit;
     }
     }