From ad8c16177e825c20c8868ac2d440762451d29c60 Mon Sep 17 00:00:00 2001 From: Scott Lahteine Date: Mon, 17 May 2021 21:17:22 -0500 Subject: [PATCH] Use defined strings --- Marlin/src/lcd/extui/mks_ui/wifi_module.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Marlin/src/lcd/extui/mks_ui/wifi_module.cpp b/Marlin/src/lcd/extui/mks_ui/wifi_module.cpp index be693a748f..a9ad9c189c 100644 --- a/Marlin/src/lcd/extui/mks_ui/wifi_module.cpp +++ b/Marlin/src/lcd/extui/mks_ui/wifi_module.cpp @@ -621,9 +621,9 @@ static void wifi_gcode_exec(uint8_t *cmd_line) { if (tmpStr == 0) { gCfgItems.fileSysType = FILE_SYS_SD; - send_to_wifi((uint8_t *)"Begin file list\r\n", strlen("Begin file list\r\n")); + send_to_wifi((uint8_t *)(STR_BEGIN_FILE_LIST "\r\n"), strlen(STR_BEGIN_FILE_LIST "\r\n")); get_file_list((char *)"0:/"); - send_to_wifi((uint8_t *)"End file list\r\n", strlen("End file list\r\n")); + send_to_wifi((uint8_t *)(STR_END_FILE_LIST "\r\n"), strlen(STR_END_FILE_LIST "\r\n")); SEND_OK_TO_WIFI; break; } @@ -634,7 +634,7 @@ static void wifi_gcode_exec(uint8_t *cmd_line) { char *path = (char *)tempBuf; if (strlen((char *)&tmpStr[index]) < 80) { - send_to_wifi((uint8_t *)"Begin file list\r\n", strlen("Begin file list\r\n")); + send_to_wifi((uint8_t *)(STR_BEGIN_FILE_LIST "\r\n"), strlen(STR_BEGIN_FILE_LIST "\r\n")); if (strncmp((char *)&tmpStr[index], "1:", 2) == 0) gCfgItems.fileSysType = FILE_SYS_SD; @@ -643,7 +643,7 @@ static void wifi_gcode_exec(uint8_t *cmd_line) { strcpy((char *)path, (char *)&tmpStr[index]); get_file_list(path); - send_to_wifi((uint8_t *)"End file list\r\n", strlen("End file list\r\n")); + send_to_wifi((uint8_t *)(STR_END_FILE_LIST "\r\n"), strlen(STR_END_FILE_LIST "\r\n")); } SEND_OK_TO_WIFI; }