diff options
author | João Abecasis <joao.abecasis@nokia.com> | 2010-05-26 18:04:57 (GMT) |
---|---|---|
committer | João Abecasis <joao.abecasis@nokia.com> | 2010-05-26 18:39:27 (GMT) |
commit | 8060094144d6104659b8ce3b88d6f8b1e53cfb59 (patch) | |
tree | 46c192629f518c2f84fbda5199e3ab7e3882b5c2 /tests/arthur/arthurtester.pri | |
parent | b7109e5ad32e6048b9051e4d5bccd88724d16d0e (diff) | |
download | Qt-8060094144d6104659b8ce3b88d6f8b1e53cfb59.zip Qt-8060094144d6104659b8ce3b88d6f8b1e53cfb59.tar.gz Qt-8060094144d6104659b8ce3b88d6f8b1e53cfb59.tar.bz2 |
Fix regression in QVarLengthArray::operator=
There was a serious regression wherei, under certain conditions,
assignment would be treated as an append. This was due to poor tracking
of container invariants inside realloc.
From now on, after the allocation decision, s shall contain the number
of elements in the array to be kept. Deleting extra elements in the old
array needn't update this value. Instead, it needs to be updated once
and if new elements are created afterwards.
Auto-test greatly expanded to avoid future embarassments.
Task-number: QTBUG-10978
Reviewed-by: Olivier Goffart
Reviewed-by: Fabien Freling
Olivier reviewed the patch, Fabien the auto-test.
Diffstat (limited to 'tests/arthur/arthurtester.pri')
0 files changed, 0 insertions, 0 deletions