2017.05.21 19:28 "[Tiff] Libtiff 4.0.8 released", by Bob Friesenhahn

2017.07.04 18:38 "Re: [Tiff] A bug in libtiff error/warning handling", by Bob Friesenhahn

A proper fix would be to deprecate the global handler variables in libtiff (which are not thread-safe anyway and will conflict between different libraries anyway) and store the handler function pointer in the TIFF structure instead, next to tif_clientdata. This would make the handler specific to a single client and then I would indeed agree there would be no need to call more than one handler at any time. I think it has been agreed earlier that this is something what is needed, but to get this fixed is obviously much more work.

This would not work for the common case of reporting an error when there is no TIFF handle. There would need to be additional parameters added for the functions which open a a TIFF.

If OS thread APIs can be used, then there is the option to use thread specific data without any API change, but a possible added library dependency.

Bob
--
Bob Friesenhahn
bfriesen@simple.dallas.tx.us, http://www.simplesystems.org/users/bfriesen/
GraphicsMagick Maintainer, http://www.GraphicsMagick.org/