From 806da08564e9a54576a4f7596765550113b5346b Mon Sep 17 00:00:00 2001 From: Mike La Spina Date: Tue, 19 Oct 2021 06:05:23 -0500 Subject: [PATCH] =?UTF-8?q?=F0=9F=A9=B9=20Fix=20pragma=20ignored=20for=20o?= =?UTF-8?q?lder=20GCC=20(#22978)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Marlin/src/gcode/gcode.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Marlin/src/gcode/gcode.cpp b/Marlin/src/gcode/gcode.cpp index 4c6efc0ed729..9459bf8918dc 100644 --- a/Marlin/src/gcode/gcode.cpp +++ b/Marlin/src/gcode/gcode.cpp @@ -1096,11 +1096,15 @@ void GcodeSuite::process_next_command() { process_parsed_command(); } +#pragma GCC diagnostic push +#if GCC_VERSION >= 80000 + #pragma GCC diagnostic ignored "-Wstringop-truncation" +#endif + /** * Run a series of commands, bypassing the command queue to allow * G-code "macros" to be called from within other G-code handlers. */ - void GcodeSuite::process_subcommands_now(FSTR_P fgcode) { PGM_P pgcode = FTOP(fgcode); char * const saved_cmd = parser.command_ptr; // Save the parser state