| Index: runtime/vm/isolate.cc
|
| diff --git a/runtime/vm/isolate.cc b/runtime/vm/isolate.cc
|
| index 06dfad2153440b67c04ff43cdeaa55d35a78a82e..bbda77fd3555578c92be46b175143c4b1fa5cc01 100644
|
| --- a/runtime/vm/isolate.cc
|
| +++ b/runtime/vm/isolate.cc
|
| @@ -900,10 +900,7 @@ void Isolate::BuildName(const char* name_prefix) {
|
| name_ = strdup(name_prefix);
|
| return;
|
| }
|
| - const char* kFormat = "%s-%lld";
|
| - intptr_t len = OS::SNPrint(NULL, 0, kFormat, name_prefix, main_port()) + 1;
|
| - name_ = reinterpret_cast<char*>(malloc(len));
|
| - OS::SNPrint(name_, len, kFormat, name_prefix, main_port());
|
| + SNPRINT(name_, malloc, "%s-%lld", name_prefix, main_port());
|
| }
|
|
|
|
|
|
|