Skip to content

Commit

Permalink
Update mach_override to upstream 1a1bb352
Browse files Browse the repository at this point in the history
CFLog, which is overridden by content/renderer/renderer_main_platform_delegate_mac.mm, contains the following instruction in 64-bit form on 10.6.8 and 10.7.5:

4881ECD0000000                  sub        rsp, 0xd0

mach_override’s puny simplistic fake disassembler didn’t understand this instruction. This resulted in mach_override failing, which triggered a CHECK failure during renderer startup, with the result that everything would be a sad tab on 10.6 and 10.7 64-bit.

The latest version of mach_override replaces its weak old non-disassembler with libudis86, which should be much more capable in the area of understanding instructions, and which should improve mach_override’s ability to patch code without always having to retrain it.

In the mean time, the upstream change that was probably causing us to be unable to update to the current HEAD (rentzsch/mach_star@498e0ba3)
has been backed out since then (rentzsch/mach_override@1b3aa46f), so it should now be safe to update to HEAD.

Local patches https://codereview.chromium.org/21208002/ and https://codereview.chromium.org/22798004/ have been reapplied with minor fixes to work with the current version.

BUG=315218
R=avi@chromium.org

Review URL: https://codereview.chromium.org/61273002

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@233175 0039d316-1c4b-4281-b951-d872f2087c98
  • Loading branch information
mark@chromium.org committed Nov 6, 2013
1 parent 5c287bf commit 0f83067
Show file tree
Hide file tree
Showing 20 changed files with 12,345 additions and 218 deletions.
29 changes: 27 additions & 2 deletions third_party/mach_override/LICENSE
Original file line number Diff line number Diff line change
@@ -1,2 +1,27 @@
Copyright (c) 2003-2009 Jonathan 'Wolf' Rentzsch: <http://rentzsch.com>
Some rights reserved: <http://opensource.org/licenses/mit-license.php>
Copyright (c) 2003-2012 Jonathan 'Wolf' Rentzsch: http://rentzsch.com
Some rights reserved: http://opensource.org/licenses/mit

mach_override includes a copy of libudis86, licensed as follows:

Copyright (c) 2002-2009 Vivek Thampi
All rights reserved.

Redistribution and use in source and binary forms, with or without modification,
are permitted provided that the following conditions are met:

* Redistributions of source code must retain the above copyright notice,
this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
18 changes: 9 additions & 9 deletions third_party/mach_override/README.chromium
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
Name: mach_override
Short Name: Part of the mach_star project
Version: Unknown
URL: https://github.com/rentzsch/mach_star
Date: 11/14/2012
Revision: 10860416803280f05cbe20f97a3ec02a7c697bf4
License: MIT
Short Name: mach_override
Version: Newer than 1.2. HEAD from branch semver-1.x.
URL: https://github.com/rentzsch/mach_override
Date: 2013-08-21
Revision: 1a1bb35291a915c545842cd64b5e12e1e76883fc
License: MIT and 2-clause BSD
Security Critical: Yes


Description:
This is the mach_override part of mach_star, namely:
https://github.com/rentzsch/mach_star/tree/10860416803280f05cbe20f97a3ec02a7c697bf4

This package is used to replace framework functions with different
implementations at run time.

mach_override includes a copy of libudis86 1.7.1, available separately from
http://udis86.sourceforge.net/ and https://github.com/vmt/udis86 .


Local Modifications:
Ensure no rwx pages remain after mach_override_ptr:
Expand Down
Loading

0 comments on commit 0f83067

Please sign in to comment.