Summary: | Loading of large Mach-O thin binaries fails. | ||
---|---|---|---|
Product: | [Developer tools] valgrind | Reporter: | Scott Byer <scottbyer> |
Component: | general | Assignee: | Julian Seward <jseward> |
Status: | RESOLVED FIXED | ||
Severity: | normal | ||
Priority: | NOR | ||
Version: | 3.7 SVN | ||
Target Milestone: | --- | ||
Platform: | Unlisted Binaries | ||
OS: | macOS | ||
Latest Commit: | Version Fixed In: | ||
Attachments: | Patch to fix the problem. |
Committed, r12739. Thanks for the diagnosis + patch. |
Created attachment 66963 [details] Patch to fix the problem. Darwin barnbyerner.mtv.corp.google.com 11.2.0 Darwin Kernel Version 11.2.0: Tue Aug 9 20:54:00 PDT 2011; root:xnu-1699.24.8~1/RELEASE_X86_64 x86_64 load_thin_file currently uses the wrong value (size instead of len) to determine the end of the headers section. A large thin binary can end up wrapping around the end pointer, causing the sanity check in the headers load loop to fail. (binary I was using was Chromium's browser_tests, as build on Lion w/ make). Patch attached.