Index: sync/util/get_session_name.cc |
diff --git a/sync/util/get_session_name.cc b/sync/util/get_session_name.cc |
index d51c93e54e63676f5d069bb34f655f7b5baf6d80..3a09c51379d393d168fa0fe1d91bb253b81ed1ca 100644 |
--- a/sync/util/get_session_name.cc |
+++ b/sync/util/get_session_name.cc |
@@ -11,10 +11,7 @@ |
#include "base/sys_info.h" |
#include "base/task_runner.h" |
-#if defined(OS_CHROMEOS) |
-#include "base/command_line.h" |
-#include "chromeos/chromeos_switches.h" |
-#elif defined(OS_LINUX) |
+#if defined(OS_LINUX) |
#include "sync/util/get_session_name_linux.h" |
#elif defined(OS_IOS) |
#include "sync/util/get_session_name_ios.h" |
@@ -33,27 +30,7 @@ namespace { |
std::string GetSessionNameSynchronously() { |
std::string session_name; |
#if defined(OS_CHROMEOS) |
- // The approach below is similar to that used by the CrOs implementation of |
- // StatisticsProvider::GetMachineStatistic(CHROMEOS_RELEASE_BOARD). |
- // See chromeos/system/statistics_provider.{h|cc}. |
- // |
- // We cannot use StatisticsProvider here because of the mutual dependency |
- // it creates between sync.gyp:sync and chrome.gyp:browser. |
- // |
- // Even though this code is ad hoc and fragile, it remains the only means of |
- // determining the Chrome OS hardware platform so we can display the right |
- // device name in the "Other devices" section of the new tab page. |
- // TODO(rsimha): Change this once a better alternative is available. |
- // See http://crbug.com/126732. |
- std::string board; |
- const CommandLine* command_line = CommandLine::ForCurrentProcess(); |
- if (command_line->HasSwitch(chromeos::switches::kChromeOSReleaseBoard)) { |
- board = command_line-> |
- GetSwitchValueASCII(chromeos::switches::kChromeOSReleaseBoard); |
- } else { |
- LOG(ERROR) << "Failed to get board information"; |
- } |
- |
+ std::string board = base::SysInfo::GetLsbReleaseBoard(); |
// Currently, only "stumpy" type of board is considered Chromebox, and |
// anything else is Chromebook. On these devices, session_name should look |
// like "stumpy-signed-mp-v2keys" etc. The information can be checked on |