瀏覽代碼

Memory tool: fix null access types (#418)

Tom SPIRA 4 年之前
父節點
當前提交
d28a856826
共有 1 個文件被更改,包括 6 次插入4 次删除
  1. 6 4
      other/memory/Memory.hx

+ 6 - 4
other/memory/Memory.hx

@@ -605,10 +605,12 @@ class Memory {
 		for( i in currentTypeIndex...types.length ) {
 		for( i in currentTypeIndex...types.length ) {
 			var t = types[i];
 			var t = types[i];
 			var tstr = t.toString();
 			var tstr = t.toString();
-			resolveCache.set(tstr, t);
-			currentTypeIndex = i + 1;
-			if( tstr == str )
-				return t;
+			if (tstr != null) {
+				resolveCache.set(tstr, t);
+				currentTypeIndex = i + 1;
+				if( tstr == str )
+					return t;
+			}
 		}
 		}
 		if( showError )
 		if( showError )
 			log("Type not found '"+str+"'");
 			log("Type not found '"+str+"'");