RESOLVED FIXED 82436
Web Inspector: REGRESSION: Stack overflow on the page with > 100kloc
https://bugs.webkit.org/show_bug.cgi?id=82436
Summary Web Inspector: REGRESSION: Stack overflow on the page with > 100kloc
Ilya Tikhonovsky
Reported 2012-03-28 01:14:15 PDT
this._setLine(range.startLine, prefix + newLines[0]); for (var i = 1; i < newLines.length; ++i) this._lines.splice(range.startLine + i, 0, newLines[i]); // Adjust attributes, attributes move with the first character of line. var spliceParameters = new Array(newLines.length + 1); // 2 + number of items to insert. spliceParameters[0] = range.startColumn ? range.startLine + 1 : range.startLine; spliceParameters[1] = 0; here --> this._attributes.splice.apply(this._attributes, spliceParameters); spliceParameters is an preallocated array with ~132k elements
Attachments
Patch (3.42 KB, patch)
2012-03-28 02:47 PDT, Pavel Feldman
yurys: review+
Pavel Feldman
Comment 1 2012-03-28 02:47:48 PDT
Yury Semikhatsky
Comment 2 2012-03-28 02:58:12 PDT
Comment on attachment 134246 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=134246&action=review > Source/WebCore/inspector/front-end/TextEditorModel.js:177 > + for (var i = 1; i < newLines.length; ++i) This looks weird here, can you add a comment?
Pavel Feldman
Comment 3 2012-03-28 03:10:33 PDT
Note You need to log in before you can comment on or make changes to this bug.