Skip to content

Commit 2abb7ed

Browse files
Issue #46 : missing use of isSentinel
1 parent ce52535 commit 2abb7ed

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/communication/Commander.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ void Commander::run(char* user_input){
6969
}
7070
break;
7171
case CMD_VERBOSE:
72-
if(user_input[1] != eol) verbose = (VerboseMode)atoi(&user_input[1]);
72+
if(!isSentinel(user_input[1])) verbose = (VerboseMode)atoi(&user_input[1]);
7373
printVerbose(F("Verb:"));
7474
switch (verbose){
7575
case VerboseMode::nothing:
@@ -82,7 +82,7 @@ void Commander::run(char* user_input){
8282
}
8383
break;
8484
case CMD_DECIMAL:
85-
if(user_input[1] != eol) decimal_places = atoi(&user_input[1]);
85+
if(!isSentinel(user_input[1])) decimal_places = atoi(&user_input[1]);
8686
printVerbose(F("Decimal:"));
8787
println(decimal_places);
8888
break;

0 commit comments

Comments
 (0)