Scripting: exit if the perf script throws an error during collection
If an exception occurs while collecting parameters, exit rather than just leaving the shell running in the main loop. https://bugzilla.gnome.org/show_bug.cgi?id=732349
This commit is contained in:
parent
b95c0682b0
commit
910c95fa9b
@ -360,7 +360,12 @@ function runPerfScript(scriptModule, outputFile) {
|
||||
|
||||
_step(g,
|
||||
function() {
|
||||
_collect(scriptModule, outputFile);
|
||||
try {
|
||||
_collect(scriptModule, outputFile);
|
||||
} catch (err) {
|
||||
log("Script failed: " + err + "\n" + err.stack);
|
||||
Meta.exit(Meta.ExitCode.ERROR);
|
||||
}
|
||||
Meta.exit(Meta.ExitCode.SUCCESS);
|
||||
},
|
||||
function(err) {
|
||||
|
Loading…
Reference in New Issue
Block a user