diff --git a/lib/node-xml.js b/lib/node-xml.js index 180a482..350bad7 100755 --- a/lib/node-xml.js +++ b/lib/node-xml.js @@ -63,7 +63,7 @@ XMLP._STATE_PROLOG = 1; XMLP._STATE_DOCUMENT = 2; XMLP._STATE_MISC = 3; -XMLP._errs = new Array(); +XMLP._errs = []; XMLP._errs[XMLP.ERR_CLOSE_PI = 0 ] = "PI: missing closing sequence"; XMLP._errs[XMLP.ERR_CLOSE_DTD = 1 ] = "DTD: missing closing sequence"; XMLP._errs[XMLP.ERR_CLOSE_COMMENT = 2 ] = "Comment: missing closing sequence"; @@ -106,7 +106,7 @@ XMLP.prototype.continueParsing = function(strXML) { } XMLP.prototype._addAttribute = function(name, value) { - this.m_atts[this.m_atts.length] = new Array(name, value); + this.m_atts[this.m_atts.length] = [name, value]; } XMLP.prototype._checkStructure = function(iEvent) {