You've already forked Adafruit_MQTT_Library
mirror of
https://github.com/adafruit/Adafruit_MQTT_Library.git
synced 2025-06-11 22:48:09 +03:00
read max packet
This commit is contained in:
@ -48,8 +48,8 @@ class Adafruit_MQTT_FONA : public Adafruit_MQTT {
|
|||||||
DEBUG_PRINT('!');
|
DEBUG_PRINT('!');
|
||||||
|
|
||||||
if (len + avail > maxlen) {
|
if (len + avail > maxlen) {
|
||||||
// oof we cant read more of the available data in this buffer
|
avail = maxlen - len;
|
||||||
return len;
|
if (avail == 0) return len;
|
||||||
}
|
}
|
||||||
|
|
||||||
// try to read the data into the end of the pointer
|
// try to read the data into the end of the pointer
|
||||||
|
Reference in New Issue
Block a user