Free ColorMatrix1 on error

Prevent a potential memory leak by freeing the allocated ColorMatrix1 if
libtiff fails.