mirror of
https://github.com/serge1/ELFIO.git
synced 2024-12-26 18:15:40 +00:00
fix mismatched allocator warning
This commit is contained in:
parent
ac542cbb8b
commit
04985836db
@ -223,7 +223,7 @@ template <class T> class section_impl : public section
|
||||
// reallocate data to be the correct size
|
||||
data.reset( new (std::nothrow) char[size_t(uncompressed_size) + 1]);
|
||||
// create a buffer to hold the compressed bits
|
||||
auto compressed_data = std::unique_ptr<char>(new char[size_t(size)]);
|
||||
auto compressed_data = std::unique_ptr<char[]>(new char[size_t(size)]);
|
||||
if( data == nullptr || compressed_data == nullptr) {
|
||||
std::cerr << "failed to allocate memory buffers for decompression" << std::endl;
|
||||
return false;
|
||||
|
Loading…
Reference in New Issue
Block a user