mesa: handle MapTextureImage() failures in glTexImage code