Removed global new operator overload (issue #40, #45 and #46)

This commit is contained in:
Benoit Blanchon
2015-02-01 20:59:31 +01:00
parent dadd8986dc
commit 8db338ba14
10 changed files with 42 additions and 35 deletions

View File

@@ -0,0 +1,21 @@
// Copyright Benoit Blanchon 2014
// MIT License
//
// Arduino JSON library
// https://github.com/bblanchon/ArduinoJson
#pragma once
#include "../JsonBuffer.hpp"
namespace ArduinoJson {
namespace Internals {
class JsonBufferAllocated {
public:
void *operator new(size_t n, JsonBuffer *jsonBuffer) throw() {
return jsonBuffer->alloc(n);
}
};
}
}