Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(653)

Unified Diff: src/messages.cc

Issue 1214373005: Do not truncate message strings. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | test/cctest/test-api.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/messages.cc
diff --git a/src/messages.cc b/src/messages.cc
index 5e050bd2909f17fcf4a27433c30f9ad15cc61093..7193392d9d1c30a196efb43407327c6d369e0348 100644
--- a/src/messages.cc
+++ b/src/messages.cc
@@ -332,7 +332,6 @@ MaybeHandle<String> MessageTemplate::FormatMessage(int template_index,
Handle<String> arg0,
Handle<String> arg1,
Handle<String> arg2) {
- static const int kMaxArgLength = 256;
Isolate* isolate = arg0->GetIsolate();
const char* template_string;
switch (template_index) {
@@ -361,16 +360,7 @@ MaybeHandle<String> MessageTemplate::FormatMessage(int template_index,
} else {
DCHECK(i < arraysize(args));
Handle<String> arg = args[i++];
- int length = arg->length();
- if (length > kMaxArgLength) {
- builder.AppendString(
- isolate->factory()->NewSubString(arg, 0, kMaxArgLength - 6));
- builder.AppendCString("...");
- builder.AppendString(
- isolate->factory()->NewSubString(arg, length - 3, length));
- } else {
- builder.AppendString(arg);
- }
+ builder.AppendString(arg);
}
} else {
builder.AppendCharacter(*c);
« no previous file with comments | « no previous file | test/cctest/test-api.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698