Prevent resource leak in PNG ICC read code