Skip to content

Commit 8796e55

Browse files
committed
Add safe value for debug server when configuring debug speed
1 parent 265dbc1 commit 8796e55

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

platform.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -159,7 +159,8 @@ def configure_debug_options(self, initial_debug_options, ide_data):
159159
debug_options = copy.deepcopy(initial_debug_options)
160160
adapter_speed = initial_debug_options.get("speed")
161161
if adapter_speed:
162-
server_executable = debug_options["server"].get("executable", "").lower()
162+
server_options = debug_options.get("server") or {}
163+
server_executable = server_options.get("executable", "").lower()
163164
if "openocd" in server_executable:
164165
debug_options["server"]["arguments"].extend(
165166
["-c", "adapter speed %s" % adapter_speed]

0 commit comments

Comments
 (0)