Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

checks: Check for game captures needing admin #170

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions checks/windows.py
Original file line number Diff line number Diff line change
Expand Up @@ -347,6 +347,18 @@ def checkAdmin(lines):
"OBS is not running as Administrator. This can lead to OBS not being able to Game Capture certain games. If you are not running into issues, you can ignore this."]


gc_admin_re = re.compile(r"could not open process: (?P<executable>.*)$")


def checkGCAdmin(lines):
error_lines = search("could not open process:", lines)
gc_error_lines = search("game-capture", error_lines) # Makes sure the error comes from a game capture, in case.
if gc_error_lines:
exe_list = set([gc_admin_re.search(line).group("executable").strip() for line in gc_error_lines])
return [LEVEL_INFO, "Game Capture permissions",
"The following games might need OBS to be run as Administrator to properly capture the following games with game capture : <br>\n<ul>\n<li>" + "</li>\n<li>".join(exe_list) + "</li>\n</ul>"]


def check32bitOn64bit(lines):
winVersion = search('Windows Version', lines)
obsVersion = getOBSVersionLine(lines)
Expand Down
1 change: 1 addition & 0 deletions loganalyzer.py
Original file line number Diff line number Diff line change
Expand Up @@ -148,6 +148,7 @@ def doAnalysis(url=None, filename=None):
checkWindowsARM64(logLines),
checkMacVer(logLines),
checkAdmin(logLines),
checkGCAdmin(logLines),
checkImports(logLines),
check32bitOn64bit(logLines),
checkWindowsARM64EmulationStatus(logLines),
Expand Down