mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 680523 - Vector move constructor needs to initialize mBegin (r=jimb)
--HG-- extra : rebase_source : ea42c66734745bfe5b3c83c10e6c5a42a19c8527
This commit is contained in:
parent
68b31a2604
commit
fd464a2828
@ -608,7 +608,7 @@ class HashTable : private AllocPolicy
|
||||
memset(table, 0, sizeof(*table) * tableCapacity);
|
||||
} else {
|
||||
for (Entry *e = table, *end = table + tableCapacity; e != end; ++e)
|
||||
*e = Entry();
|
||||
*e = Move(Entry());
|
||||
}
|
||||
removedCount = 0;
|
||||
entryCount = 0;
|
||||
|
@ -506,6 +506,7 @@ Vector<T, N, AllocPolicy>::Vector(MoveRef<Vector> rhs)
|
||||
|
||||
if (rhs->usingInlineStorage()) {
|
||||
/* We can't move the buffer over in this case, so copy elements. */
|
||||
mBegin = (T *)storage.addr();
|
||||
Impl::moveConstruct(mBegin, rhs->beginNoCheck(), rhs->endNoCheck());
|
||||
/*
|
||||
* Leave rhs's mLength, mBegin, mCapacity, and mReserved as they are.
|
||||
|
Loading…
Reference in New Issue
Block a user