diff options
Diffstat (limited to 'src/corelib/tools/qarraydataops.h')
-rw-r--r-- | src/corelib/tools/qarraydataops.h | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/corelib/tools/qarraydataops.h b/src/corelib/tools/qarraydataops.h index 13d5572c03..d50c74f2c2 100644 --- a/src/corelib/tools/qarraydataops.h +++ b/src/corelib/tools/qarraydataops.h @@ -916,11 +916,10 @@ public: DataPointer old; // points into range: - if (QtPrivate::q_points_into_range(b, this->begin(), this->end())) { + if (QtPrivate::q_points_into_range(b, *this)) this->detachAndGrow(QArrayData::GrowsAtEnd, n, &b, &old); - } else { + else this->detachAndGrow(QArrayData::GrowsAtEnd, n, nullptr, nullptr); - } Q_ASSERT(this->freeSpaceAtEnd() >= n); // b might be updated so use [b, n) this->copyAppend(b, b + n); |