forked from bblanchon/ArduinoJson
Test that size can't go above capacity
This commit is contained in:
@ -14,7 +14,12 @@ public:
|
||||
|
||||
virtual ~StaticJsonBuffer() {}
|
||||
|
||||
/*JsonObject*/void createObject() { _size++; }
|
||||
/*JsonObject*/
|
||||
void createObject()
|
||||
{
|
||||
if (_size < CAPACITY)
|
||||
_size++;
|
||||
}
|
||||
|
||||
int capacity()
|
||||
{
|
||||
|
Reference in New Issue
Block a user