summaryrefslogtreecommitdiff
authormouse <mouse>2004-03-31 14:54:16 (UTC)
committer mouse <mouse>2004-03-31 14:54:16 (UTC)
commit0a56adea03683be6066622bbbbae1f0b8c73db12 (patch) (side-by-side diff)
tree9b2ff9aabd303397edd12cd2589d7fb25315308c
parent4f6dbea16af4c6edb7cdc619be4cacf672f8aee8 (diff)
downloadopie-0a56adea03683be6066622bbbbae1f0b8c73db12.zip
opie-0a56adea03683be6066622bbbbae1f0b8c73db12.tar.gz
opie-0a56adea03683be6066622bbbbae1f0b8c73db12.tar.bz2
dirty bugfix (segfault with scaleFactor > 1), see inside for more info
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--noncore/comm/keypebble/krfbbuffer.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/noncore/comm/keypebble/krfbbuffer.cpp b/noncore/comm/keypebble/krfbbuffer.cpp
index 92918d4..4cec0c2 100644
--- a/noncore/comm/keypebble/krfbbuffer.cpp
+++ b/noncore/comm/keypebble/krfbbuffer.cpp
@@ -190,5 +190,7 @@ void KRFBBuffer::drawRawRectChunk( void *data,
if (scaleFactor > 1) {
- p.drawImage( x/scaleFactor, y/scaleFactor, img.smoothScale(w/scaleFactor,h/scaleFactor) );
+ /* FIXME: proper zero width/height handling */
+ if (w/scaleFactor != 0)
+ p.drawImage( x/scaleFactor, y/scaleFactor, img.smoothScale(w/scaleFactor,h/scaleFactor) );
emit updated( x/scaleFactor, y/scaleFactor, w/scaleFactor, h/scaleFactor );
}