X-Git-Url: https://git.carlh.net/gitweb/?a=blobdiff_plain;f=src%2Fwx%2Fgrok%2Fgpu_config_panel.h;h=2647c1ece60d166c83d0928faa59caaab5d5ba46;hb=1e1acbc8487a06de5e35a14742ea82f7afa8e2e3;hp=1478434be01188699fa1f0cbe3418d27d927a9c2;hpb=7a95493bd2e6348135dbdbd4297af7971584742f;p=dcpomatic.git diff --git a/src/wx/grok/gpu_config_panel.h b/src/wx/grok/gpu_config_panel.h index 1478434be..2647c1ece 100644 --- a/src/wx/grok/gpu_config_panel.h +++ b/src/wx/grok/gpu_config_panel.h @@ -3,7 +3,9 @@ static std::vector get_gpu_names(std::string binary, std::string filename) { // Execute the GPU listing program and redirect its output to a file - std::system((binary + " > " + filename).c_str()); + if (std::system((binary + " > " + filename).c_str()) < 0) { + return {}; + } std::vector gpu_names; std::ifstream file(filename);