From 5e0d1703c63d1eea0daa2e6eece7927f1ce3e7fe Mon Sep 17 00:00:00 2001 From: Vincent van Ravesteijn Date: Thu, 19 Nov 2009 22:28:51 +0000 Subject: [PATCH] branch: Fix bug #6327: Crash in new file and press PgUp button. git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/branches/BRANCH_1_6_X@32102 a592a061-630c-0410-9148-cb99ea01b6c8 --- src/TextMetrics.cpp | 2 +- status.16x | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/src/TextMetrics.cpp b/src/TextMetrics.cpp index f13dc566f9..c3719dd30e 100644 --- a/src/TextMetrics.cpp +++ b/src/TextMetrics.cpp @@ -1458,7 +1458,7 @@ Row const & TextMetrics::getPitAndRowNearY(int & y, pit_type & pit, if (rit != rlast) { y = yy + rit->height(); ++rit; - } else if (pit != int(par_metrics_.size())) { + } else if (pit < int(par_metrics_.size()) - 1) { ++pit; newParMetricsDown(); ParagraphMetrics const & pm2 = par_metrics_[pit]; diff --git a/status.16x b/status.16x index 22cce0cdc3..59e36a819e 100644 --- a/status.16x +++ b/status.16x @@ -211,6 +211,8 @@ What's new - Fix an infinite loop when selecting multiple displayed equation right after each other with LFUN_SCREEN_UP (bug 6237). + +- Fix a crash when pressing PageUp in an empty document (bug 6327). - Fix a number of assertions when displaying error messages (bug 6205).