Skip to content

Commit

Permalink
thing
Browse files Browse the repository at this point in the history
  • Loading branch information
altalk23 committed Jun 2, 2024
1 parent 982a96c commit 6e49000
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
8 changes: 4 additions & 4 deletions src/Handler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -117,10 +117,10 @@ void Handler::updateHookMetadata(HookHandle const& hook, HookMetadata const& met
void Handler::reorderFunctions() {
auto& vec = m_content->m_functions;
std::cout << "functions size " << vec.size() << std::endl;
std::sort(vec.begin(), vec.end(), [this](auto const a, auto const b) {
std::cout << "reordering " << m_handles[a] << " " << m_handles[b] << std::endl;
return (m_hooks.at(m_handles[a])->m_metadata.m_priority < m_hooks.at(m_handles[b])->m_metadata.m_priority);
});
// std::sort(vec.begin(), vec.end(), [this](auto const a, auto const b) {
// std::cout << "reordering " << m_handles[a] << " " << m_handles[b] << std::endl;
// return (m_hooks.at(m_handles[a])->m_metadata.m_priority < m_hooks.at(m_handles[b])->m_metadata.m_priority);
// });
std::cout << "sorted\n";
}

Expand Down
4 changes: 2 additions & 2 deletions src/generator/X64Generator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -166,9 +166,9 @@ std::vector<uint8_t> X64HandlerGenerator::handlerBytes(uint64_t address) {
// call the func
m_metadata.m_convention->generateIntoDefault(a, m_metadata.m_abstract);

// a.mov(RAX, m[RBP - 0x10]);
a.mov(RAX, m[RBP - 0x10]);
// // a.int3();
// a.call(RAX);
a.call(RAX);
// // a.int3();
m_metadata.m_convention->generateDefaultCleanup(a, m_metadata.m_abstract);

Expand Down

0 comments on commit 6e49000

Please sign in to comment.