diff options
author | Andrei Golubev <andrei.golubev@qt.io> | 2021-02-09 14:03:04 +0100 |
---|---|---|
committer | Qt Cherry-pick Bot <cherrypick_bot@qt-project.org> | 2021-02-10 14:46:42 +0000 |
commit | dca5a2ca39d45ec7ac1472f438328b3b941bcad1 (patch) | |
tree | 7081f9a8531f46996f12d925a1b0f92cb05d26f6 /LICENSE.QT-LICENSE-AGREEMENT | |
parent | ab9032acbb6a6ffb0a4fd43eee8a4fe8bbf27ca1 (diff) |
Restore pre-Qt6 QList::fill() behavior
Somehow QList::fill(t, newSize) introduced a regression in Qt6:
when newSize < QList::size() we should resize to the newSize.
This is aligned with QVector::fill() in 5.15 and std::vector::assign()
While 6.0 is already out, picking it to 6.0.x could save someone who
haven't migrated yet as well as fix some accidental bugs in Qt's code
[ChangeLog][QtCore][QList] Fixed QList::fill() regression introduced in
6.0: calling fill() with size < current list size wouldn't truncate the
list
Fixes: QTBUG-91042
Change-Id: Ic166e2c5e42390b61df1030f7c705e344433f7f2
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
(cherry picked from commit 6512a7fc642c65455db770385c67cfa6d71c294c)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Diffstat (limited to 'LICENSE.QT-LICENSE-AGREEMENT')
0 files changed, 0 insertions, 0 deletions