tiff/tiff-3.8.2-tiff2pdf.patch

12 lines
400 B
Diff

--- tools/tiff2pdf.c
+++ tools/tiff2pdf.c
@@ -3668,7 +3668,7 @@
written += TIFFWriteFile(output, (tdata_t) "(", 1);
for (i=0;i<len;i++){
if((pdfstr[i]&0x80) || (pdfstr[i]==127) || (pdfstr[i]<32)){
- sprintf(buffer, "\\%.3o", pdfstr[i]);
+ sprintf(buffer, "\\%.3o", (unsigned char)(pdfstr[i]));
written += TIFFWriteFile(output, (tdata_t) buffer, 4);
} else {
switch (pdfstr[i]){