summaryrefslogtreecommitdiffstats
path: root/base/sys_info_mac.cc
diff options
context:
space:
mode:
authorjeremy@chromium.org <jeremy@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-08-21 22:30:47 +0000
committerjeremy@chromium.org <jeremy@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-08-21 22:30:47 +0000
commit3a3e5b3c585d110766921a79997b4c6ab8a49440 (patch)
tree2969b47e71db438b56b572cd8b5e37ab3d818fa4 /base/sys_info_mac.cc
parentfe474ed7f9eee2c666a3be32336c359c67d40fc4 (diff)
downloadchromium_src-3a3e5b3c585d110766921a79997b4c6ab8a49440.zip
chromium_src-3a3e5b3c585d110766921a79997b4c6ab8a49440.tar.gz
chromium_src-3a3e5b3c585d110766921a79997b4c6ab8a49440.tar.bz2
Some tweaks to the OS X Sandbox:
* Fix 10.6 bug where garbled text was displayed due to insuccesful font loading. * Tightened down the Sandbox a bit, instead of allowing access to /System/Library limit it to certain subdirectories. * Remove unused warmup code now that we allow sysctl-read. BUG=11269 BUG=b/1853366 TEST=On 10.6, copy Arial.ttf from /System/Library/Fonts to ~/Library/Fonts , Launch Chrome. Text on NTP should be displayed normally and not garbled. Review URL: http://codereview.chromium.org/174254 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@24030 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/sys_info_mac.cc')
-rw-r--r--base/sys_info_mac.cc15
1 files changed, 3 insertions, 12 deletions
diff --git a/base/sys_info_mac.cc b/base/sys_info_mac.cc
index caec74d..54b7320 100644
--- a/base/sys_info_mac.cc
+++ b/base/sys_info_mac.cc
@@ -12,21 +12,12 @@ namespace base {
void SysInfo::OperatingSystemVersionNumbers(int32 *major_version,
int32 *minor_version,
int32 *bugfix_version) {
- int32 major_version_cached = 0;
- int32 minor_version_cached = 0;
- int32 bugfix_version_cached = 0;
-
- // Gestalt can't be called in the sandbox, so we cache its return value.
Gestalt(gestaltSystemVersionMajor,
- reinterpret_cast<SInt32*>(&major_version_cached));
+ reinterpret_cast<SInt32*>(major_version));
Gestalt(gestaltSystemVersionMinor,
- reinterpret_cast<SInt32*>(&minor_version_cached));
+ reinterpret_cast<SInt32*>(minor_version));
Gestalt(gestaltSystemVersionBugFix,
- reinterpret_cast<SInt32*>(&bugfix_version_cached));
-
- *major_version = major_version_cached;
- *minor_version = minor_version_cached;
- *bugfix_version = bugfix_version_cached;
+ reinterpret_cast<SInt32*>(bugfix_version));
}
} // namespace base