mirror of
https://github.com/valitydev/thrift.git
synced 2024-11-06 18:35:19 +00:00
Fix uint64_t to size_t conversion warning
Fixes an MSVC warning with an explicit cast. Client: cpp
This commit is contained in:
parent
dfae5d7f4a
commit
0ebf3ce99d
@ -372,7 +372,7 @@ void TMemoryBuffer::ensureCanWrite(uint32_t len) {
|
||||
}
|
||||
|
||||
// Allocate into a new pointer so we don't bork ours if it fails.
|
||||
auto* new_buffer = static_cast<uint8_t*>(std::realloc(buffer_, new_size));
|
||||
auto* new_buffer = static_cast<uint8_t*>(std::realloc(buffer_, static_cast<std::size_t>(new_size)));
|
||||
if (new_buffer == nullptr) {
|
||||
throw std::bad_alloc();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user