Test if texture name is not -1 before binding.

As -1 seems to be the name MG uses to mark deleted texture,this should be ok.