File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -1890,7 +1890,10 @@ function cmake.register_dap_function()
18901890
18911891 if opt .target then
18921892 -- explicit target requested. use that instead of the configured one
1893- return cmake .build ({ target = opt .target }, function ()
1893+ return cmake .build ({ target = opt .target }, function (build_result )
1894+ if not build_result :is_ok () then
1895+ return
1896+ end
18941897 local model = config :get_code_model_info ()[opt .target ]
18951898 local result = config :get_launch_target_from_info (model )
18961899 local dap_config = {
@@ -1932,7 +1935,10 @@ function cmake.register_dap_function()
19321935 -- Build select launch target every time
19331936 return cmake .build (
19341937 { target = config .launch_target , fargs = utils .deepcopy (opt .fargs ) },
1935- function ()
1938+ function (build_result )
1939+ if not build_result :is_ok () then
1940+ return
1941+ end
19361942 result = config :get_launch_target ()
19371943 local target_path = result .data
19381944 local dap_config = {
You can’t perform that action at this time.
0 commit comments