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
@ -1,5 +1,6 @@
|
|||||||
<node>
|
<node>
|
||||||
<interface name="org.gnome.Shell.PerfHelper">
|
<interface name="org.gnome.Shell.PerfHelper">
|
||||||
|
<method name="Exit"/>
|
||||||
<method name="CreateWindow">
|
<method name="CreateWindow">
|
||||||
<arg type="i" direction="in"/>
|
<arg type="i" direction="in"/>
|
||||||
<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}`);
|
log(`Script failed: ${err}\n${err.stack}`);
|
||||||
Meta.exit(Meta.ExitCode.ERROR);
|
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);
|
Meta.exit(Meta.ExitCode.SUCCESS);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user