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

Side by Side Diff: base/sys_info_mac.cc

Issue 16320009: Use a direct include of strings headers in base/. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 6 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « base/sys_info_android.cc ('k') | base/sys_info_win.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "base/sys_info.h" 5 #include "base/sys_info.h"
6 6
7 #include <ApplicationServices/ApplicationServices.h> 7 #include <ApplicationServices/ApplicationServices.h>
8 #include <CoreServices/CoreServices.h> 8 #include <CoreServices/CoreServices.h>
9 #include <mach/mach_host.h> 9 #include <mach/mach_host.h>
10 #include <mach/mach_init.h> 10 #include <mach/mach_init.h>
11 #include <sys/sysctl.h> 11 #include <sys/sysctl.h>
12 #include <sys/types.h> 12 #include <sys/types.h>
13 13
14 #include "base/logging.h" 14 #include "base/logging.h"
15 #include "base/mac/scoped_mach_port.h" 15 #include "base/mac/scoped_mach_port.h"
16 #include "base/stringprintf.h" 16 #include "base/strings/stringprintf.h"
17 17
18 namespace base { 18 namespace base {
19 19
20 // static 20 // static
21 std::string SysInfo::OperatingSystemName() { 21 std::string SysInfo::OperatingSystemName() {
22 return "Mac OS X"; 22 return "Mac OS X";
23 } 23 }
24 24
25 // static 25 // static
26 std::string SysInfo::OperatingSystemVersion() { 26 std::string SysInfo::OperatingSystemVersion() {
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
79 // static 79 // static
80 std::string SysInfo::CPUModelName() { 80 std::string SysInfo::CPUModelName() {
81 char name[256]; 81 char name[256];
82 size_t len = arraysize(name); 82 size_t len = arraysize(name);
83 if (sysctlbyname("machdep.cpu.brand_string", &name, &len, NULL, 0) == 0) 83 if (sysctlbyname("machdep.cpu.brand_string", &name, &len, NULL, 0) == 0)
84 return name; 84 return name;
85 return std::string(); 85 return std::string();
86 } 86 }
87 87
88 } // namespace base 88 } // namespace base
OLDNEW
« no previous file with comments | « base/sys_info_android.cc ('k') | base/sys_info_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698