javascript can't complete a for..in.. loop (mootools 1.11 in use)
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
firefox-3.0 (Ubuntu) |
Invalid
|
Undecided
|
Unassigned |
Bug Description
Binary package hint: firefox
I was trying to complete a loop with the for..in.. sentence. In all the others browsers (iexplorer, opera, safari for windows, opera for linux) the loop finish without errors, but in Firefox (for windows and Linux) appears the error:
[Exception... "Component returned failure code: 0x80004005 (NS_ERROR_FAILURE) [nsIDOMNSHTMLIn
The html code only includes 2 external JavaScript code: the mootools library and other that includes this function (it try to extract information about a object)
function debugEl (elem) {
var aux = '';
for(iter in elem) {
if(iter && elem[iter]) // the error appears here !!
aux += "<br />\n· '"+iter+"' : "+elem[iter];
}
return aux.length+"<br /><br />\n\n"+aux;
}
it seams to crash when 'elem' take a html element value.
is it a mootools error?
ProblemType: Bug
Architecture: i386
Date: Mon Jun 25 10:59:10 2007
DistroRelease: Ubuntu 7.04
Package: firefox 2.0.0.4+1-0ubuntu1
PackageArchitec
SourcePackage: firefox
Uname: Linux santi-linux 2.6.20-16-generic #2 SMP Thu Jun 7 20:19:32 UTC 2007 i686 GNU/Linux
i think i have seen this bug reported in launchbad already. taggging as likely-dup