Index: base/sys_info_posix.cc |
diff --git a/base/sys_info_posix.cc b/base/sys_info_posix.cc |
index 85ae039118986d211ea3964e38f271c4beb3a026..0ed9065ef9f03d4890856652490f8c2ee95c91b4 100644 |
--- a/base/sys_info_posix.cc |
+++ b/base/sys_info_posix.cc |
@@ -113,8 +113,8 @@ std::string SysInfo::OperatingSystemName() { |
#if !defined(OS_MACOSX) && !defined(OS_ANDROID) |
// static |
std::string SysInfo::OperatingSystemVersion() { |
- struct utsname info; |
- if (uname(&info) < 0) { |
+ static struct utsname info = {}; |
rickyz (no longer on Chrome)
2016/06/28 05:58:00
Did this previously need to be thread safe?
Julien Isorce Samsung
2016/06/28 16:01:40
piman noted ealier that this change is not thread
|
+ if (!strlen(info.release) && uname(&info) < 0) { |
NOTREACHED(); |
return std::string(); |
} |