Implementation of TIFFCreateCustomDirectory overwrites previously merged custom tags.
If you use TIFFCreateEXIFDirectory or TIFFCreateGPSirectory the implementation of TIFFCreateCustomDirectory overwrites previously merged custom tags. TIFFDefaultDirectory merges custom tags previously registered using TIFFSetTagExtender on every directory creation but implementation of TIFFCreateCustomDirectory uses _TIFFSetupFields(tif, infoarray) and overwrites custom tags to the exif or gps tags only. As result custom tags can't be used to customize exif or gps directories or any custom directories (but for them you can provide tag array so it ok). found on libtiff 4.5
Steps to reproduce
Register tag extender using standard TIFFSetTagExtender and try to extend exif or gps directories using custom tags.
Platform
all