aboutsummaryrefslogtreecommitdiff
path: root/disassembler_no_op.cc
AgeCommit message (Collapse)Author
2021-07-23[Zucchini]: Fix CHECK failure in ApplyCalder Kitagawa
Fixes a CHECK failure in Zucchini Apply found by ClusterFuzz. Scenario: A disassembler parses an image element and shrinks it to be the understood size. Apply expects that this understood size is identical to the size of the element it is trying to patch. This expectation will always hold for "good" patch data but for an arbitary patch may not. This results in a CHECK failure when getting reference writers. Solution: After parsing, check that the disassembler sizes match their respective image sizes. Fail to Apply and print an error message if this is not the case. Bug: 847278 Change-Id: I96edb738b8f9ea2d16193ea1aa2def7319ee8f70 Reviewed-on: https://chromium-review.googlesource.com/1076369 Commit-Queue: Calder Kitagawa <ckitagawa@chromium.org> Reviewed-by: Samuel Huang <huangs@chromium.org> Cr-Commit-Position: refs/heads/master@{#562560} NOKEYCHECK=True GitOrigin-RevId: 0ca1928abfdce0efe539655cc09e9a8f4ece063f
2021-07-23[Zucchini] Zucchini-gen: Make number of CreateEquivalenceMap() generations ↵Samuel Huang
depend on Disassembler. The number of CreateEquivalenceMap() iterations used be constant kNumIteraitons = 2. This CL makes the value depend on architecture. Current assignment: - DisassemblerNoOp: 1, since no pointers are identified (though in this case, CreateEquivalenceMap() should not be called). - DisassemblerWin32: 2. Upcoming DisassemblerDex will use 4. Also applying generic cleanups on headers and comments. Bug: 729154 Change-Id: Ia12d98fcba500e4c81c8a5d356ce4cadf424ffde Reviewed-on: https://chromium-review.googlesource.com/961273 Reviewed-by: agrieve <agrieve@chromium.org> Commit-Queue: Samuel Huang <huangs@chromium.org> Cr-Commit-Position: refs/heads/master@{#542919} NOKEYCHECK=True GitOrigin-RevId: 55aea0a875b80e614464fdd157d9717471f9d64f
2021-07-23[Zucchini] Move Zucchini from /chrome/installer/ to /components/.Samuel Huang
(Use "git log --follow" to see older revisions of files). /components/ is the most logical place to put Zucchini, which only depends on /base and /testing/gtest. This move also enables Zucchini to be used by the Component Updater. Details: - Move all files; run the following to change deps and guards: sed 's/chrome\/installer/components/' *.cc *.h -i sed 's/CHROME_INSTALLER/COMPONENTS/' *.cc *.h -i - Sorting works out pretty well! - Change all 'chrome/installer/zucchini' to 'components/zucchini' throughout other parts of the repo; sort if necessary. - Fix 6 'git cl lint' errors. - Change 1 Bind() usage to BindRepeated(). - Update OWNER. Bug: 729154 Change-Id: I50c5a7d411ea85f707b5994ab319dfb2a1acccf7 Reviewed-on: https://chromium-review.googlesource.com/954923 Reviewed-by: Greg Thompson <grt@chromium.org> Reviewed-by: Jochen Eisinger <jochen@chromium.org> Reviewed-by: Samuel Huang <huangs@chromium.org> Commit-Queue: Samuel Huang <huangs@chromium.org> Cr-Commit-Position: refs/heads/master@{#542857} NOKEYCHECK=True GitOrigin-RevId: 577ef6c435e8d43be6e3e60ccbcbd1881780f4ec