From 625df03c157f960032e99768e84732df1f5eb102 Mon Sep 17 00:00:00 2001 From: d-millar <33498836+d-millar@users.noreply.github.com> Date: Thu, 20 Jun 2024 11:42:25 -0400 Subject: [PATCH] GP-4704: expanded gdb.parameter logic GP-4704: expanded gdb.parameter logic --- .../Debugger-agent-gdb/src/main/py/src/ghidragdb/arch.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Ghidra/Debug/Debugger-agent-gdb/src/main/py/src/ghidragdb/arch.py b/Ghidra/Debug/Debugger-agent-gdb/src/main/py/src/ghidragdb/arch.py index bd5367955e..bf9fa2ee7e 100644 --- a/Ghidra/Debug/Debugger-agent-gdb/src/main/py/src/ghidragdb/arch.py +++ b/Ghidra/Debug/Debugger-agent-gdb/src/main/py/src/ghidragdb/arch.py @@ -104,7 +104,7 @@ def get_arch(): def get_endian(): parm = gdb.parameter('endian') - if parm != 'auto': + if not parm in ['', 'auto', 'default']: return parm # Once again, we have to hack using the human-readable 'show' show = gdb.execute('show endian', to_string=True) @@ -132,7 +132,7 @@ def get_osabi(): def compute_ghidra_language(): # First, check if the parameter is set lang = gdb.parameter('ghidra-language') - if lang != 'auto': + if not lang in ['', 'auto', 'default']: return lang # Get the list of possible languages for the arch. We'll need to sift @@ -157,7 +157,7 @@ def compute_ghidra_language(): def compute_ghidra_compiler(lang): # First, check if the parameter is set comp = gdb.parameter('ghidra-compiler') - if comp != 'auto': + if not comp in ['', 'auto', 'default']: return comp # Check if the selected lang has specific compiler recommendations