Added a check in utils.run() that the "args" argument is not
a string to avoid a common misuse case.

Signed-off-by: Mihai Rusu <dizzy@google.com>


git-svn-id: http://test.kernel.org/svn/autotest/trunk@4023 592f7852-d20e-0410-864c-8624ca9c26a4
diff --git a/client/common_lib/utils.py b/client/common_lib/utils.py
index ddbb34b..bda72e2 100644
--- a/client/common_lib/utils.py
+++ b/client/common_lib/utils.py
@@ -373,6 +373,10 @@
 
     @raise CmdError: the exit code of the command execution was not 0
     """
+    if isinstance(args, basestring):
+        raise TypeError('Got a string for the "args" keyword argument, '
+                        'need a sequence.')
+
     for arg in args:
         command += ' "%s"' % sh_escape(arg)
     if stderr_is_expected is None: