win-capture: Make sure we don't try to hook ourselves

Can trigger when using "Hook any fullscreen application" is enabled and
the projector is active.
上级 853ec3cb
......@@ -831,6 +831,10 @@ static void try_hook(struct game_capture *gc)
gc->thread_id = GetWindowThreadProcessId(gc->next_window,
&gc->process_id);
// Make sure we never try to hook ourselves (projector)
if (gc->process_id == GetCurrentProcessId())
return;
if (!gc->thread_id || !gc->process_id) {
warn("error acquiring, failed to get window "
"thread/process ids: %lu",
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册