Browse Source

fixed infinite loop in JS.

Nicolas Cannasse 19 years ago
parent
commit
f31310e5be
1 changed files with 2 additions and 0 deletions
  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++;