diff options
author | Bryn M. Reeves <bmr@redhat.com> | 2014-10-15 15:51:13 +0100 |
---|---|---|
committer | Bryn M. Reeves <bmr@redhat.com> | 2014-10-15 15:51:13 +0100 |
commit | f9aefde0d7f74867031a00b52f72d0ad1ff9463b (patch) | |
tree | 07ad9fa182778de5e9cbe0226aadb9869908e1b1 | |
parent | 6b43c42078604b0551923c2801108848e97ba3b9 (diff) | |
download | sos-f9aefde0d7f74867031a00b52f72d0ad1ff9463b.tar.gz |
[ovirt_hosted_engine] fix exception when force-enabled
Fixes #416.
Signed-off-by: Bryn M. Reeves <bmr@redhat.com>
-rw-r--r-- | sos/plugins/ovirt_hosted_engine.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sos/plugins/ovirt_hosted_engine.py b/sos/plugins/ovirt_hosted_engine.py index aee8bc0a..02cb2b62 100644 --- a/sos/plugins/ovirt_hosted_engine.py +++ b/sos/plugins/ovirt_hosted_engine.py @@ -56,8 +56,9 @@ class OvirtHostedEngine(Plugin, RedHatPlugin): all_setup_logs = glob.glob(self.SETUP_LOG_GLOB) all_setup_logs.sort(reverse=True) - # Add latest ovirt-hosted-engine-setup log file - self.add_copy_spec(all_setup_logs[0]) + if len(all_setup_logs): + # Add latest ovirt-hosted-engine-setup log file + self.add_copy_spec(all_setup_logs[0]) # Add older ovirt-hosted-engine-setup log files only if requested if self.get_option('all_logs'): self.add_copy_spec_limit( |