Index: base/linux_util.cc |
diff --git a/base/linux_util.cc b/base/linux_util.cc |
index 67514696c5c2dc4f3244b2b060aed6760e6429fd..2544136cdb376f9734ceeb40db9b3591e67e77b8 100644 |
--- a/base/linux_util.cc |
+++ b/base/linux_util.cc |
@@ -154,9 +154,9 @@ std::string GetLinuxDistro() { |
base::GetAppOutput(CommandLine(argv), &output); |
if (output.length() > 0) { |
// lsb_release -d should return: Description:<tab>Distro Info |
- static const std::string field = "Description:\t"; |
- if (output.compare(0, field.length(), field) == 0) { |
- SetLinuxDistro(output.substr(field.length())); |
+ static const char field[] = "Description:\t"; |
Mark Mentovai
2011/11/09 21:13:45
This doesn’t even need to be static.
Nico
2011/11/09 21:24:07
Done. Does it make any difference though? String l
Mark Mentovai
2011/11/09 21:29:10
Nico wrote:
|
+ if (output.compare(0, strlen(field), field) == 0) { |
+ SetLinuxDistro(output.substr(strlen(field))); |
} |
} |
distro_state_singleton->CheckFinished(); |