MCPcopy Create free account
hub / github.com/ElementsProject/elements / allocate

Method allocate

src/support/allocators/secure.h:40–47  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

38 };
39
40 T* allocate(std::size_t n, const void* hint = 0)
41 {
42 T* allocation = static_cast<T*>(LockedPoolManager::Instance().alloc(sizeof(T) * n));
43 if (!allocation) {
44 throw std::bad_alloc();
45 }
46 return allocation;
47 }
48
49 void deallocate(T* p, std::size_t n)
50 {

Callers

nothing calls this directly

Calls 1

allocMethod · 0.80

Tested by

no test coverage detected