From a98cc0d90d05e6240a6cd8c11e6be715d44b41ee Mon Sep 17 00:00:00 2001 From: Preston Brown Date: Wed, 10 Nov 1999 19:01:14 +0000 Subject: [PATCH] sanity check parameters to moveImage. Just print a warning and return if they are insane. Not the best fix, but I don't know enough to figure out what should really happen... svn path=/trunk/kdebase/konsole/; revision=33437 --- src/TEScreen.C | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/TEScreen.C b/src/TEScreen.C index 8362c836..94efcd77 100644 --- a/src/TEScreen.C +++ b/src/TEScreen.C @@ -862,6 +862,10 @@ void TEScreen::clearImage(int loca, int loce, char c) void TEScreen::moveImage(int dst, int loca, int loce) { //FIXME: check positions + if (loce < loca) { + qDebug("WARNING!!! call to TEScreen:moveImage with loce < loca!"); + return; + } memmove(&image[dst],&image[loca],(loce-loca+1)*sizeof(ca)); }