diff --git a/src/corelib/tools/qlist.h b/src/corelib/tools/qlist.h index 3f621e71fb9..f93b60d4bbd 100644 --- a/src/corelib/tools/qlist.h +++ b/src/corelib/tools/qlist.h @@ -528,6 +528,9 @@ inline void QList::squeeze() detached->copyAppend(constBegin(), constEnd()); } d.swap(detached); + } else { + // We're detached so this is fine + d->clearFlag(Data::CapacityReserved); } }