Package: libimlib2 Version: 1.2.1-2 Severity: normal Tags: patch *** Please type your report below this line ***
Attempting to save an image that has alpha causes a segfault. The problem is the misuse of TIFFSetField() in src/modules/loaders/loader_tiff.c:save(). To reproduce: Open a TIFF image with semitransparent pixels in feh. Press s. feh crashes. --- loader_tiff.c 2004-12-14 05:50:46.000000000 +0200 +++ loader_tiff-savealpha.c 2006-08-03 00:06:28.742378356 +0300 @@ -387,8 +387,9 @@ if (has_alpha) { + uint16 extras[] = { EXTRASAMPLE_ASSOCALPHA }; TIFFSetField(tif, TIFFTAG_SAMPLESPERPIXEL, 4); - TIFFSetField(tif, TIFFTAG_EXTRASAMPLES, EXTRASAMPLE_ASSOCALPHA); + TIFFSetField(tif, TIFFTAG_EXTRASAMPLES, 1, extras); } else { -- System Information: Debian Release: testing/unstable APT prefers testing APT policy: (500, 'testing') Architecture: amd64 (x86_64) Shell: /bin/sh linked to /bin/bash Kernel: Linux 2.6.16-2-amd64-k8-smp Locale: LANG=en_US, LC_CTYPE=en_US (charmap=ISO-8859-1) (ignored: LC_ALL set to en_US) Versions of packages libimlib2 depends on: ii libbz2-1.0 1.0.3-3 high-quality block-sorting file co ii libc6 2.3.6-15 GNU C Library: Shared libraries ii libfreetype6 2.2.1-2 FreeType 2 font engine, shared lib ii libjpeg62 6b-13 The Independent JPEG Group's JPEG ii libpng12-0 1.2.8rel-5.1 PNG library - runtime ii libtiff4 3.8.2-5 Tag Image File Format (TIFF) libra ii libungif4g 4.1.4-2 shared library for GIF images (run ii libx11-6 2:1.0.0-7 X11 client-side library ii libxext6 1:1.0.0-4 X11 miscellaneous extension librar ii zlib1g 1:1.2.3-13 compression library - runtime libimlib2 recommends no packages. -- no debconf information -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]