H
hiqu
This issue is driving me nuts and not able to figure out whats wrong.
I've this code in my firefox extension. Firefox always hangs and
reports the script is busy.
if I introduce a break statement in the for(; loop below, then
no issue.
Any help would be appreciated!
function getStuff()
{
try
{
httpReq = new XMLHttpRequest();
httpReq.onreadystatechange = function(evt)
{
if (httpReq.readyState == 4)
{
if (httpReq.status == 200)
{
getList(httpReq.responseText);
}
}
}
httpReq.open("GET", "http://www.mysite.com", true);
httpReq.send(null);
}catch(ex)
{
Components.utils.reportError(ex);
}
}
function getList(htmlText)
{
for(;
{
}
}
I've this code in my firefox extension. Firefox always hangs and
reports the script is busy.
if I introduce a break statement in the for(; loop below, then
no issue.
Any help would be appreciated!
function getStuff()
{
try
{
httpReq = new XMLHttpRequest();
httpReq.onreadystatechange = function(evt)
{
if (httpReq.readyState == 4)
{
if (httpReq.status == 200)
{
getList(httpReq.responseText);
}
}
}
httpReq.open("GET", "http://www.mysite.com", true);
httpReq.send(null);
}catch(ex)
{
Components.utils.reportError(ex);
}
}
function getList(htmlText)
{
for(;
{
}
}