perf-tool: Only 'restore' gnome-shell if run with --replace

Otherwise the perf tool will fork and spawn a gnome-shell process
that'll just go and fail.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/1349>
This commit is contained in:
Jonas Ådahl 2021-03-16 10:29:36 +01:00
parent faff190364
commit b56f853103

View File

@ -320,7 +320,7 @@ if args:
normal_exit = run_performance_test() normal_exit = run_performance_test()
if normal_exit: if normal_exit:
if not options.hwtest: if not options.hwtest and options.replace:
restore_shell() restore_shell()
else: else:
sys.exit(1) sys.exit(1)