浏览代码

fixed infinite loop in JS.

Nicolas Cannasse 19 年之前
父节点
当前提交
f31310e5be
共有 1 个文件被更改,包括 2 次插入0 次删除
  1. 2 0
      std/haxe/Unserializer.hx

+ 2 - 0
std/haxe/Unserializer.hx

@@ -43,6 +43,8 @@ class Unserializer {
  		var s = false;
  		while( true ) {
  			var c = buf.charCodeAt(pos) - 48;
+ 			if( Std.isNaN(c) )
+ 				break;
  			if( c == -3 ) {
  				s = true;
  				pos++;