Please review at your convenience. Issue: https://bugs.openjdk.java.net/browse/JDK-8144245 Patch: http://cr.openjdk.java.net/~bpb/8144245/webrev.00/
For the principal issue, the stream position was not being reset when the write was aborted to either the header position or to the position of the current IFD, as appropriate. As part of the investigation, a missing check in TIFFIFD was discovered. Also, a few occurrences in TIFFImageWriter of a NullPointerException being thrown where an IllegalArgumentException was expected were corrected. Lastly, the test was slightly modified to iterate over all registered writers and fail at the end instead of bailing out on the first failure. Thanks, Brian