aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Adam <obnox@samba.org>2016-12-13 11:07:03 +0100
committerBryn M. Reeves <bmr@redhat.com>2017-03-28 14:12:07 +0100
commitd5731e11e291dcfe7f28d5bd87e0029ca9058cd8 (patch)
treecb9cc101d427a746f506eb20118044b2ac0d0019
parent1be8920355f054763540c6f8aa86adabab0963e9 (diff)
downloadsos-d5731e11e291dcfe7f28d5bd87e0029ca9058cd8.tar.gz
[plugins] implement add_copy_spec() by calling add_copy_spec_limit()
Signed-off-by: Michael Adam <obnox@samba.org>
-rw-r--r--sos/plugins/__init__.py15
1 files changed, 1 insertions, 14 deletions
diff --git a/sos/plugins/__init__.py b/sos/plugins/__init__.py
index 8f1bb74e..6a89e463 100644
--- a/sos/plugins/__init__.py
+++ b/sos/plugins/__init__.py
@@ -556,20 +556,7 @@ class Plugin(object):
self.archive.add_link(link_path, _file)
def add_copy_spec(self, copyspecs):
- """Add a file specification (can be file, dir,or shell glob) to be
- copied into the sosreport by this module.
- """
- if isinstance(copyspecs, six.string_types):
- copyspecs = [copyspecs]
- for copyspec in copyspecs:
- if self.use_sysroot():
- copyspec = self.join_sysroot(copyspec)
- if not (copyspec and len(copyspec)):
- self._log_warn("added null or empty copy spec")
- return False
- copy_paths = self._expand_copy_spec(copyspec)
- self._add_copy_paths(copy_paths)
- self._log_info("added copyspec '%s'" % copy_paths)
+ self.add_copy_spec_limit(copyspecs)
def get_command_output(self, prog, timeout=300, stderr=True,
chroot=True, runat=None, env=None):