From f2efd3b13371ae8bda3d16a077efa5688004e8e6 Mon Sep 17 00:00:00 2001 From: Thibault Saunier Date: Thu, 7 Oct 2021 19:41:07 -0300 Subject: [PATCH] validate:launcher: Fix potential invalid index access Part-of: --- subprojects/gst-devtools/validate/launcher/baseclasses.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/subprojects/gst-devtools/validate/launcher/baseclasses.py b/subprojects/gst-devtools/validate/launcher/baseclasses.py index 5f9f29f..c05bc99 100644 --- a/subprojects/gst-devtools/validate/launcher/baseclasses.py +++ b/subprojects/gst-devtools/validate/launcher/baseclasses.py @@ -807,7 +807,8 @@ class GstValidateListener(socketserver.BaseRequestHandler, Loggable): # Make sure that action end is taken into account when checking if process # is updating test.position += 1 - test.actions_infos[-1]['execution-duration'] = obj['execution-duration'] + if test.actions_infos: + test.actions_infos[-1]['execution-duration'] = obj['execution-duration'] elif obj_type == 'report': test.add_report(obj) elif obj_type == 'skip-test': -- 2.7.4