From: Jim Morris Date: Wed, 3 Oct 2018 17:49:15 +0000 (+0100) Subject: ignore any line that starts with ok X-Git-Url: http://git.hcoop.net/clinton/Smoothieware.git/commitdiff_plain/4b107a157eb01a28541098a10cfae37d8437c8c1 ignore any line that starts with ok --- diff --git a/src/modules/utils/simpleshell/SimpleShell.cpp b/src/modules/utils/simpleshell/SimpleShell.cpp index b11f0317..67e70144 100644 --- a/src/modules/utils/simpleshell/SimpleShell.cpp +++ b/src/modules/utils/simpleshell/SimpleShell.cpp @@ -275,9 +275,9 @@ void SimpleShell::on_console_line_received( void *argument ) } else if (cmd == "fire") { // these are handled by Laser module - } else if (cmd == "ok") { - // probably an echo so reply ok - new_message.stream->printf("ok\n"); + } else if (cmd.substr(0, 2) == "ok") { + // probably an echo so ignore the whole line + //new_message.stream->printf("ok\n"); }else if(!parse_command(cmd.c_str(), possible_command, new_message.stream)) { new_message.stream->printf("error:Unsupported command - %s\n", cmd.c_str());