From e22bc848947cd2139eaef235ac14e76004d0297d Mon Sep 17 00:00:00 2001 From: Vincent Koc Date: Thu, 26 Nov 2026 00:43:43 +0800 Subject: [PATCH] refactor(ghidra): share the executable file probe (#14573) --- src/ghidra/GhidraInstallation.ts | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/src/ghidra/GhidraInstallation.ts b/src/ghidra/GhidraInstallation.ts index bc27cecd83..f2d82f6c47 100644 --- a/src/ghidra/GhidraInstallation.ts +++ b/src/ghidra/GhidraInstallation.ts @@ -1134,16 +1134,7 @@ export const systemGhidraInstallationHost = (): GhidraInstallationHost => ({ } }, executableHeader: readGhidraExecutableHeader, - executable(path) { - try { - accessSync(path, constants.X_OK); - return statSync(path).isFile(); - } catch (cause: unknown) { - // best-effort cleanup: optional executable probing; failure means missing. - void cause; - return false; - } - }, + executable: executablePath, probeJava: probeGhidraJava, discoverInstallDirOnPath: discoverGhidraInstallationOnPath, });