mirror of
https://github.com/edu4rdshl/gnome-shell.git
synced 2026-07-18 07:34:54 +00:00
scripting: Exit helper after running test
This avoids the helper process exiting with an error due to a broken pipe. Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1349>
This commit is contained in:
parent
6fc538b7f7
commit
67d965d560
2 changed files with 10 additions and 0 deletions
|
|
@ -1,5 +1,6 @@
|
|||
<node>
|
||||
<interface name="org.gnome.Shell.PerfHelper">
|
||||
<method name="Exit"/>
|
||||
<method name="CreateWindow">
|
||||
<arg type="i" direction="in"/>
|
||||
<arg type="i" direction="in"/>
|
||||
|
|
|
|||
|
|
@ -284,6 +284,15 @@ async function _runPerfScript(scriptModule, outputFile) {
|
|||
log(`Script failed: ${err}\n${err.stack}`);
|
||||
Meta.exit(Meta.ExitCode.ERROR);
|
||||
}
|
||||
|
||||
try {
|
||||
const perfHelper = _getPerfHelper();
|
||||
perfHelper.ExitSync();
|
||||
} catch (err) {
|
||||
log(`Failed to exit helper: ${err}\n${err.stack}`);
|
||||
Meta.exit(Meta.ExitCode.ERROR);
|
||||
}
|
||||
|
||||
Meta.exit(Meta.ExitCode.SUCCESS);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue