win-capture: Don't hard fail if thread ID not found
Under certain circumstances, the program may not be able to acquire the window thread ID for a UWP process, but will be able to acquire the process ID. In this case, it should soft fail and retry, rather than assume it's unacquirable and stop trying to reacquire.master
parent
a5337605cd
commit
b3119e0a8d
|
@ -1186,7 +1186,9 @@ static void try_hook(struct game_capture *gc)
|
|||
if (gc->process_id == GetCurrentProcessId())
|
||||
return;
|
||||
|
||||
if (!gc->thread_id || !gc->process_id) {
|
||||
if (!gc->thread_id && gc->process_id)
|
||||
return;
|
||||
if (!gc->process_id) {
|
||||
warn("error acquiring, failed to get window "
|
||||
"thread/process ids: %lu",
|
||||
GetLastError());
|
||||
|
|
Loading…
Reference in New Issue