Fixed a bug with the PNG lib.