Browse Source

Fix null allocPos crash

trethaller 7 years ago
parent
commit
50d9779a43
1 changed files with 2 additions and 1 deletions
  1. 2 1
      h3d/mat/Texture.hx

+ 2 - 1
h3d/mat/Texture.hx

@@ -261,7 +261,8 @@ class Texture {
 		if( t != null ) {
 			mem.deleteTexture(this);
 			#if debug
-			this.allocPos.customParams = ["#DISPOSED"];
+			if(this.allocPos != null)
+				this.allocPos.customParams = ["#DISPOSED"];
 			#end
 		}
 	}