~satchmo/libvmm

db8ecec8cc355857e515812c5f080dd6f5e8f763 — Jason Phan 4 months ago 6379010
memory: Fix GuestAddress' align operation

The bitwise NOT operator in C++ is ~, not !.
1 files changed, 1 insertions(+), 1 deletions(-)

M vmm/memory/detail/guest.cpp
M vmm/memory/detail/guest.cpp => vmm/memory/detail/guest.cpp +1 -1
@@ 41,7 41,7 @@ auto GuestAddress::operator-(const_reference addr) const noexcept -> value_type
auto GuestAddress::align(const size_type alignment) noexcept -> void
{
    const auto mask = alignment - 1;
    m_addr = (*this + mask) & !mask;
    m_addr = (*this + mask) & ~mask;
}

}  // vmm::memory::detail