summaryrefslogtreecommitdiff
path: root/sc
diff options
context:
space:
mode:
authorChristian Lohmaier <lohmaier+LibreOffice@googlemail.com>2015-10-25 00:18:12 +0200
committerChristian Lohmaier <lohmaier+LibreOffice@googlemail.com>2015-10-25 00:22:16 +0200
commit4607005c380f230d8a44671f91a456598dfe6081 (patch)
tree70cc16074a23953e8290f71c4b9265aa4af7403a /sc
parentf7c8774b2f3423095d794e90c58ab505ef8a1706 (diff)
fraction assert kills Android viewer when viewing e.g. a ods with just a note
use SAL_WARN_IF instead - getting logged with info is more suitable for this - useless zoom factors won't cause other problems Change-Id: I7b8dd6551297eeff8e720ff85702f0049a4b93a2
Diffstat (limited to 'sc')
-rw-r--r--sc/source/ui/view/viewdata.cxx6
1 files changed, 4 insertions, 2 deletions
diff --git a/sc/source/ui/view/viewdata.cxx b/sc/source/ui/view/viewdata.cxx
index 9e6b151acc1d..aa1daef67f97 100644
--- a/sc/source/ui/view/viewdata.cxx
+++ b/sc/source/ui/view/viewdata.cxx
@@ -629,8 +629,10 @@ void ScViewData::SetZoom( const Fraction& rNewX, const Fraction& rNewY, std::vec
CreateTabData( tabs );
// sanity check - we shouldn't need something this low / big
- assert(rNewX > Fraction(1, 100) && rNewX < Fraction(100, 1));
- assert(rNewY > Fraction(1, 100) && rNewY < Fraction(100, 1));
+ SAL_WARN_IF(rNewX < Fraction(1, 100) || rNewX > Fraction(100, 1), "sal_viewdata",
+ "fraction rNewX not sensible: " << (double) rNewX);
+ SAL_WARN_IF(rNewY < Fraction(1, 100) || rNewY > Fraction(100, 1), "sal_viewdata",
+ "fraction rNewY not sensible: " << (double) rNewY);
if ( bAll )
{