From 3ce7b9c988b382275628c75f04becd18acf29dc1 Mon Sep 17 00:00:00 2001 From: pgoodman <43664+pgoodman@users.noreply.github.com> Date: Mon, 4 Nov 2024 00:23:23 +0000 Subject: [PATCH 1/2] Bump Ghidra HEAD commit ffaa97cbd Changed files: ``` M Ghidra/Features/Decompiler/src/decompile/cpp/block.cc M Ghidra/Features/Decompiler/src/decompile/cpp/block.hh M Ghidra/Features/Decompiler/src/decompile/cpp/blockaction.cc M Ghidra/Features/Decompiler/src/decompile/cpp/constseq.cc M Ghidra/Features/Decompiler/src/decompile/cpp/constseq.hh M Ghidra/Features/Decompiler/src/decompile/cpp/flow.cc M Ghidra/Features/Decompiler/src/decompile/cpp/funcdata.hh M Ghidra/Features/Decompiler/src/decompile/cpp/funcdata_op.cc M Ghidra/Features/Decompiler/src/decompile/cpp/ifacedecomp.cc M Ghidra/Features/Decompiler/src/decompile/cpp/ruleaction.cc M Ghidra/Features/Decompiler/src/decompile/cpp/subflow.cc M Ghidra/Features/Decompiler/src/decompile/cpp/subflow.hh M Ghidra/Features/Decompiler/src/decompile/cpp/type.cc M Ghidra/Features/Decompiler/src/decompile/cpp/type.hh M Ghidra/Features/Decompiler/src/decompile/cpp/typeop.cc M Ghidra/Features/Decompiler/src/decompile/cpp/typeop.hh A Ghidra/Features/Decompiler/src/decompile/datatests/inline.xml ``` --- src/setup-ghidra-source.cmake | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/setup-ghidra-source.cmake b/src/setup-ghidra-source.cmake index 3192967fa..f21d09ee4 100644 --- a/src/setup-ghidra-source.cmake +++ b/src/setup-ghidra-source.cmake @@ -52,7 +52,7 @@ if("${sleigh_RELEASE_TYPE}" STREQUAL "HEAD") # TODO: CMake only likes numeric characters in the version string.... set(ghidra_head_version "11.3") set(ghidra_version "${ghidra_head_version}") - set(ghidra_head_git_tag "7ddd8665b7dd9bc4f6ef6d91fc5b81add61ba14d") + set(ghidra_head_git_tag "ffaa97cbd986e71143d45260cd31167ed0917a96") set(ghidra_git_tag "${ghidra_head_git_tag}") set(ghidra_shallow FALSE) set(ghidra_patches From f8278f3e6ab237e6c442e45e00e533b015630bb6 Mon Sep 17 00:00:00 2001 From: Eric Kilmer Date: Sun, 3 Nov 2024 19:36:35 -0500 Subject: [PATCH 2/2] Remove index-check patch merged in upstream --- ...x-check-to-prevent-errors-in-Windows.patch | 26 ------------------- src/setup-ghidra-source.cmake | 1 - 2 files changed, 27 deletions(-) delete mode 100644 src/patches/HEAD/0003-Add-missing-index-check-to-prevent-errors-in-Windows.patch diff --git a/src/patches/HEAD/0003-Add-missing-index-check-to-prevent-errors-in-Windows.patch b/src/patches/HEAD/0003-Add-missing-index-check-to-prevent-errors-in-Windows.patch deleted file mode 100644 index 451d31373..000000000 --- a/src/patches/HEAD/0003-Add-missing-index-check-to-prevent-errors-in-Windows.patch +++ /dev/null @@ -1,26 +0,0 @@ -From 26a110b55617237c910447b576752fa0acb6a146 Mon Sep 17 00:00:00 2001 -From: Eric Kilmer -Date: Sat, 30 Mar 2024 18:46:16 -0400 -Subject: [PATCH 3/6] Add missing index check to prevent errors in Windows - -Not sure why this only appears when testing on Windows. ---- - Ghidra/Features/Decompiler/src/decompile/cpp/ifacedecomp.cc | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - -diff --git a/Ghidra/Features/Decompiler/src/decompile/cpp/ifacedecomp.cc b/Ghidra/Features/Decompiler/src/decompile/cpp/ifacedecomp.cc -index 455d35bffe..04bc55619c 100644 ---- a/Ghidra/Features/Decompiler/src/decompile/cpp/ifacedecomp.cc -+++ b/Ghidra/Features/Decompiler/src/decompile/cpp/ifacedecomp.cc -@@ -1848,7 +1848,7 @@ void IfcProtooverride::execute(istream &s) - s >> ws; - Address callpoint(parse_machaddr(s,discard,*dcp->conf->types)); - int4 i; -- for(i=0;dcp->fd->numCalls();++i) -+ for(i=0;ifd->numCalls();++i) - if (dcp->fd->getCallSpecs(i)->getOp()->getAddr() == callpoint) break; - if (i == dcp->fd->numCalls()) - throw IfaceExecutionError("No call is made at this address"); --- -2.47.0 - diff --git a/src/setup-ghidra-source.cmake b/src/setup-ghidra-source.cmake index f21d09ee4..4c1c6ea0e 100644 --- a/src/setup-ghidra-source.cmake +++ b/src/setup-ghidra-source.cmake @@ -61,7 +61,6 @@ if("${sleigh_RELEASE_TYPE}" STREQUAL "HEAD") "${GIT_EXECUTABLE}" am --ignore-space-change --ignore-whitespace --no-gpg-sign "${CMAKE_CURRENT_LIST_DIR}/patches/HEAD/0001-Fix-UBSAN-errors-in-decompiler.patch" "${CMAKE_CURRENT_LIST_DIR}/patches/HEAD/0002-Use-stroull-instead-of-stroul-to-parse-address-offse.patch" - "${CMAKE_CURRENT_LIST_DIR}/patches/HEAD/0003-Add-missing-index-check-to-prevent-errors-in-Windows.patch" "${CMAKE_CURRENT_LIST_DIR}/patches/HEAD/0004-Use-string-resize-instead-of-reserve.patch" "${CMAKE_CURRENT_LIST_DIR}/patches/HEAD/0005-Ignore-floating-point-test-due-to-compilation-differ.patch" "${CMAKE_CURRENT_LIST_DIR}/patches/HEAD/0006-Allow-positive-or-negative-NAN-in-decompiler-floatin.patch"