diff options
author | Qt Continuous Integration System <qt-info@nokia.com> | 2011-03-21 16:15:09 (GMT) |
---|---|---|
committer | Qt Continuous Integration System <qt-info@nokia.com> | 2011-03-21 16:15:09 (GMT) |
commit | d3f6ef8177f53968b22ba3585eef3ca2c3d5be1d (patch) | |
tree | 0edd650941d517e60c9c1f91da458133bdfb33d2 | |
parent | 12689cc05936d675c8a7065cf39b8334b83f95bb (diff) | |
parent | fda299f55dd5aeb2d075f6f5c842f75c9f559f9c (diff) | |
download | Qt-d3f6ef8177f53968b22ba3585eef3ca2c3d5be1d.zip Qt-d3f6ef8177f53968b22ba3585eef3ca2c3d5be1d.tar.gz Qt-d3f6ef8177f53968b22ba3585eef3ca2c3d5be1d.tar.bz2 |
Merge branch '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-2 into 4.7-integration
* '4.7' of scm.dev.nokia.troll.no:qt/oslo-staging-2:
Don't crash calling QTextDocument::blockBoundingRect on invalid block
-rw-r--r-- | src/gui/text/qtextdocumentlayout.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gui/text/qtextdocumentlayout.cpp b/src/gui/text/qtextdocumentlayout.cpp index a1dcb63..5e59341 100644 --- a/src/gui/text/qtextdocumentlayout.cpp +++ b/src/gui/text/qtextdocumentlayout.cpp @@ -3148,7 +3148,7 @@ QRectF QTextDocumentLayoutPrivate::frameBoundingRectInternal(QTextFrame *frame) QRectF QTextDocumentLayout::blockBoundingRect(const QTextBlock &block) const { Q_D(const QTextDocumentLayout); - if (d->docPrivate->pageSize.isNull()) + if (d->docPrivate->pageSize.isNull() || !block.isValid()) return QRectF(); d->ensureLayoutedByPosition(block.position() + block.length()); QTextFrame *frame = d->document->frameAt(block.position()); |