Commit 34c1db2f authored by mstarzinger's avatar mstarzinger Committed by Commit bot

Fix nasty off-by-one in the TurboFan JSON tracer.

R=danno@chromium.org
TEST=cctest/test-run-intrinsics/CallFunction

Review URL: https://codereview.chromium.org/916873002

Cr-Commit-Position: refs/heads/master@{#26604}
parent 71784ec0
......@@ -838,7 +838,7 @@ Handle<Code> Pipeline::GenerateCode() {
if (!script->IsUndefined() && !script->source()->IsUndefined()) {
DisallowHeapAllocation no_allocation;
int start = function->start_position();
int len = function->end_position() - start + 1;
int len = function->end_position() - start;
String::SubStringRange source(String::cast(script->source()), start,
len);
for (const auto& c : source) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment