From f029640ee6365c58ebfe66ebf6bf1733d322f2ec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Trygve=20Laugst=C3=B8l?= Date: Fri, 23 Feb 2018 03:29:44 +0100 Subject: [PATCH] Fixing compiler warnings exposed with -Wall and -Wextra: qos can't be less than zero. (#274) --- src/PubSubClient.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/PubSubClient.cpp b/src/PubSubClient.cpp index 5932bdb..603fcc8 100755 --- a/src/PubSubClient.cpp +++ b/src/PubSubClient.cpp @@ -468,7 +468,7 @@ boolean PubSubClient::subscribe(const char* topic) { } boolean PubSubClient::subscribe(const char* topic, uint8_t qos) { - if (qos < 0 || qos > 1) { + if (qos > 1) { return false; } if (MQTT_MAX_PACKET_SIZE < 9 + strlen(topic)) {