diff --git a/minmea.c b/minmea.c index 32f7881..e0e0939 100644 --- a/minmea.c +++ b/minmea.c @@ -79,7 +79,7 @@ bool minmea_check(const char *sentence, bool strict) } // The only stuff allowed at this point is a newline. - if (*sentence && strcmp(sentence, "\n") && strcmp(sentence, "\r\n")) + if (*sentence && strcmp(sentence, "\n") != 0 && strcmp(sentence, "\r") != 0 && strcmp(sentence, "\r\n") != 0) return false; return true;