summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--HISTORY4
-rw-r--r--bitmap.c2
2 files changed, 4 insertions, 2 deletions
diff --git a/HISTORY b/HISTORY
index a2ae203..4865ab0 100644
--- a/HISTORY
+++ b/HISTORY
@@ -1,10 +1,12 @@
VDR Plugin 'text2skin' Revision History
---------------------------------------
-20xx-xx-xx: Version 1.4
+____-__-__: Version 1.3.1
- Fixed some compiler warnings.
- Makefile adjustments for VDR 1.7.13.
+- Fixed segmentation fault with 16bit images (closes #258 - thanks to
+ domml@vdrportal)
2009-10-06: Version 1.3
diff --git a/bitmap.c b/bitmap.c
index 87252ea..2a9037c 100644
--- a/bitmap.c
+++ b/bitmap.c
@@ -181,7 +181,7 @@ bool cText2SkinBitmap::LoadNonXpm(const char *Filename, int height, int width, i
return false;
}
*/
- bmp = new cBitmap(w, h, (*it).depth());
+ bmp = new cBitmap(w, h, std::min((*it).depth(), 8U));
//Dprintf("this image has %d colors\n", (*it).totalColors());
const PixelPacket *pix = (*it).getConstPixels(0, 0, w, h);