Fix a delete[] mismatch in PNG error path