fixed a memory bug at setting material texture path