From 3cc6660ca44888920bea28d7136531e8d40986a8 Mon Sep 17 00:00:00 2001 From: mrexodia Date: Thu, 21 Jan 2016 02:20:45 +0100 Subject: [PATCH] added entrypoint parameter to ScyllaStartGui --- Scylla/FunctionExport.cpp | 3 ++- Scylla/FunctionExport.h | 1 + Scylla/MainGui.cpp | 2 ++ Scylla_Exports.txt | 2 +- 4 files changed, 6 insertions(+), 2 deletions(-) diff --git a/Scylla/FunctionExport.cpp b/Scylla/FunctionExport.cpp index f7f8c1a..20ce01d 100644 --- a/Scylla/FunctionExport.cpp +++ b/Scylla/FunctionExport.cpp @@ -168,11 +168,12 @@ BOOL WINAPI ScyllaDumpProcessA(DWORD_PTR pid, const char * fileToDump, DWORD_PTR } } -INT WINAPI ScyllaStartGui(DWORD dwProcessId, HINSTANCE mod) +INT WINAPI ScyllaStartGui(DWORD dwProcessId, HINSTANCE mod, DWORD_PTR entrypoint) { GUI_DLL_PARAMETER guiParam; guiParam.dwProcessId = dwProcessId; guiParam.mod = mod; + guiParam.entrypoint = entrypoint; return InitializeGui(hDllModule, (LPARAM)&guiParam); } diff --git a/Scylla/FunctionExport.h b/Scylla/FunctionExport.h index 4e970b3..78c3dea 100644 --- a/Scylla/FunctionExport.h +++ b/Scylla/FunctionExport.h @@ -13,6 +13,7 @@ const int SCY_ERROR_PIDNOTFOUND = -5; typedef struct _GUI_DLL_PARAMETER { DWORD dwProcessId; HINSTANCE mod; + DWORD_PTR entrypoint; } GUI_DLL_PARAMETER, *PGUI_DLL_PARAMETER; int InitializeGui(HINSTANCE hInstance, LPARAM param); diff --git a/Scylla/MainGui.cpp b/Scylla/MainGui.cpp index aff604d..92e3211 100644 --- a/Scylla/MainGui.cpp +++ b/Scylla/MainGui.cpp @@ -114,6 +114,8 @@ void MainGui::InitDllStartWithPreSelect( PGUI_DLL_PARAMETER guiParam ) } } } + if (guiParam->entrypoint) + EditOEPAddress.SetValue(guiParam->entrypoint); } BOOL MainGui::OnInitDialog(CWindow wndFocus, LPARAM lInitParam) diff --git a/Scylla_Exports.txt b/Scylla_Exports.txt index 10bab30..6b88745 100644 --- a/Scylla_Exports.txt +++ b/Scylla_Exports.txt @@ -13,7 +13,7 @@ const WCHAR * __stdcall ScyllaVersionInformationW(); const char * __stdcall ScyllaVersionInformationA(); DWORD __stdcall ScyllaVersionInformationDword(); -int __stdcall ScyllaStartGui(DWORD dwProcessId, HINSTANCE mod); +int __stdcall ScyllaStartGui(DWORD dwProcessId, HINSTANCE mod, DWORD_PTR entrypoint); int __stdcall ScyllaIatSearch(DWORD dwProcessId, DWORD_PTR * iatStart, DWORD * iatSize, DWORD_PTR searchStart, BOOL advancedSearch); int __stdcall ScyllaIatFixAutoW(DWORD_PTR iatAddr, DWORD iatSize, DWORD dwProcessId, const WCHAR * dumpFile, const WCHAR * iatFixFile);