mirror of
https://github.com/NationalSecurityAgency/ghidra.git
synced 2026-01-06 20:53:55 -05:00
GP-0: Fixing PyGhidra version check when things like "-BETA" are present
This commit is contained in:
@@ -396,7 +396,8 @@ class PyGhidraLauncher:
|
||||
Checks if the currently installed Ghidra version is supported.
|
||||
The launcher will report the problem and terminate if it is not supported.
|
||||
"""
|
||||
if Version(self.app_info.version) < Version(MINIMUM_GHIDRA_VERSION):
|
||||
base_version = self.app_info.version.split('-')[0] # remove things like "-BETA"
|
||||
if Version(base_version) < Version(MINIMUM_GHIDRA_VERSION):
|
||||
msg = f"Ghidra version {self.app_info.version} is not supported" + os.linesep + \
|
||||
f"The minimum required version is {MINIMUM_GHIDRA_VERSION}"
|
||||
self._report_fatal_error("Unsupported Version", msg, ValueError(msg))
|
||||
@@ -744,7 +745,7 @@ def _run_mac_app():
|
||||
return res
|
||||
|
||||
CFRunLoopTimerCallback = CFUNCTYPE(None, c_void_p, c_void_p)
|
||||
kCFRunLoopDefaultMode = c_void_p.in_dll(CoreFoundation, "kCFRunLoopDefaultMode")
|
||||
kCFRunLoopDefaultMode = c_void_p.in_dll(CoreFoundation, "kCFRunLoopDefaultMode") # @UndefinedVariable
|
||||
kCFRunLoopRunFinished = c_int32(1)
|
||||
NULL = c_void_p(0)
|
||||
INF_TIME = c_double(1.0e20)
|
||||
|
||||
Reference in New Issue
Block a user