Added GetErrorTexture function.
Added memory leak detector