1998.04.07 15:06 "Bug report for v3.4", by Tim Smith
In TIFFWriteNormalTag, there is no case for TIFF_BYTE. The case for TIFF_UNDEFINED works correctly for TIFF_BYTE is you add a case statement. I found this when extending tifflib to handle a Photoshop produced file.
case TIFF_BYTE: //Tim added
case TIFF_UNDEFINED:
{ char* cp;
if (wc == (u_short) TIFF_VARIABLE) {
TIFFGetField(tif, fip->field_tag, &wc, &cp);
dir->tdir_count = wc;
} else if (wc == (u_short) TIFF_VARIABLE2) {
TIFFGetField(tif, fip->field_tag, &wc2, &cp);
dir->tdir_count = wc2;
} else
TIFFGetField(tif, fip->field_tag, &cp);
if (!TIFFWriteByteArray(tif, dir, cp))
return (0);
}
break;