libtiff: Fixed setting of alpha value per report on list

From 38a0ad1dbdf1067e46260eb8f40fc6522f23f465 Mon Sep 17 00:00:00 2001
From: Frank Warmerdam <[EMAIL REDACTED]>
Date: Fri, 5 Oct 2007 16:59:57 +0000
Subject: [PATCH] Fixed setting of alpha value per report on list

---
 ChangeLog        | 4 ++++
 tools/tiff2pdf.c | 4 ++--
 2 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/ChangeLog b/ChangeLog
index 32c8b941..3198bbec 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2007-10-05  Frank Warmerdam  <warmerdam@pobox.com>
+
+	* tools/tiff2pdf.c: Fixed setting of alpha value per report on list.
+
 2007-09-13  Frank Warmerdam  <warmerdam@pobox.com>
 
 	* tif_dirinfo.c:  _TIFFMergeFields() now only merges in field
diff --git a/tools/tiff2pdf.c b/tools/tiff2pdf.c
index 65df421a..43aeca03 100644
--- a/tools/tiff2pdf.c
+++ b/tools/tiff2pdf.c
@@ -1,4 +1,4 @@
-/* $Id: tiff2pdf.c,v 1.37.2.4 2007-07-12 17:25:44 dron Exp $
+/* $Id: tiff2pdf.c,v 1.37.2.5 2007-10-05 16:59:57 fwarmerdam Exp $
  *
  * tiff2pdf - converts a TIFF image to a PDF document
  *
@@ -1552,7 +1552,7 @@ void t2p_read_tiff_data(T2P* t2p, TIFF* input){
 				t2p->pdf_palette[(i*4)]  = (unsigned char) (r[i]>>8);
 				t2p->pdf_palette[(i*4)+1]= (unsigned char) (g[i]>>8);
 				t2p->pdf_palette[(i*4)+2]= (unsigned char) (b[i]>>8);
-				t2p->pdf_palette[(i*4)+2]= (unsigned char) (a[i]>>8);
+				t2p->pdf_palette[(i*4)+3]= (unsigned char) (a[i]>>8);
 			}
 			t2p->pdf_palettesize *= 4;
 			break;