diff options
author | Adam Mitz <mitza@objectcomputing.com> | 2021-11-05 10:27:48 -0500 |
---|---|---|
committer | Adam Mitz <mitza@objectcomputing.com> | 2021-11-05 10:27:48 -0500 |
commit | 05799339af7c3c80b8de34451fec513aa2afc4dd (patch) | |
tree | 9b7621b3211fcbdcd39d07fdcb3b1119c7e12b1f | |
parent | 4ffb9d10827d95f58716cb868d2b8a4af5af2f56 (diff) | |
download | ATCD-05799339af7c3c80b8de34451fec513aa2afc4dd.tar.gz |
Resolve "ambiguous call to overloaded operator" with /std:c++20
(cherry picked from commit fd83ab71c26234f56b7e8bfb3794c7058b923dcc)
-rw-r--r-- | ACE/ace/Malloc_T.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ACE/ace/Malloc_T.cpp b/ACE/ace/Malloc_T.cpp index 0f966f99c8f..2d8236f0a20 100644 --- a/ACE/ace/Malloc_T.cpp +++ b/ACE/ace/Malloc_T.cpp @@ -683,7 +683,7 @@ ACE_Malloc_T<ACE_MEM_POOL_2, ACE_LOCK, ACE_CB>::shared_malloc (size_t nbytes) // Skip over the MALLOC_HEADER when returning pointer. return currp + 1; } - else if (currp == this->cb_ptr_->freep_) + else if (currp == static_cast<MALLOC_HEADER *> (this->cb_ptr_->freep_)) { // We've wrapped around freelist without finding a // block. Therefore, we need to ask the memory pool for @@ -809,7 +809,7 @@ ACE_Malloc_T<ACE_MEM_POOL_2, ACE_LOCK, ACE_CB>::shared_free (void *ap) } // Join to upper neighbor. - if ((blockp + blockp->size_) == currp->next_block_) + if (blockp + blockp->size_ == static_cast<MALLOC_HEADER *> (currp->next_block_)) { ACE_MALLOC_STATS (--this->cb_ptr_->malloc_stats_.nblocks_); blockp->size_ += currp->next_block_->size_; |