Getting java.lang.StackOverflowError , when following HTML loaded:
<html>
<body>
<script language=javascript>
var c=0;
</script>
<input id=txt1 type=text value=":)" onfocus="this.value=c;c++;txt2.focus();" />
<input id=txt2 type=text value=":)" onfocus="this.value=c;c++;txt1.focus();" />
<script language=javascript>
var txt1 = document.getElementById("txt1");
var txt2 = document.getElementById("txt2");
txt1.focus();
</script>
</body>
</html>
Sample HTML
Tried 2.7 - it hangs
It hangs sometimes, but not always
patch
Not sure if we should fix it.
From my tests:
- IE6 hangs
- FF seems to perform 2 focus events and then stops
- Chrome performs a lot of focus events and then stops when field values have reached 6134 and 6136
Did you test with other IE versions?
IE8 hangs too, Chrome throws uncaught RangeError exception ("Maximum call stack size exceeded"), when values have reached 3067 and 3065, Firefox performs 2 focus events and then stops. I think it should be fixed at least for FF
BTW: Found out, that Chromium throws 1024 Uncaught exceptions
Diff: