[yum-cvs] yum shell.py,1.39,1.40
Seth Vidal
skvidal at linux.duke.edu
Thu Jun 21 18:36:46 UTC 2007
Update of /home/groups/yum/cvs/yum
In directory login1.linux.duke.edu:/tmp/cvs-serv1430
Modified Files:
shell.py
Log Message:
make sure we don't pass shlex.split() None or it will spin, forever.
Index: shell.py
===================================================================
RCS file: /home/groups/yum/cvs/yum/shell.py,v
retrieving revision 1.39
retrieving revision 1.40
diff -u -r1.39 -r1.40
--- shell.py 2 May 2007 23:19:32 -0000 1.39
+++ shell.py 21 Jun 2007 18:36:44 -0000 1.40
@@ -45,6 +45,9 @@
"""split the input using shlex rules, and error or exit accordingly"""
inputs = []
+ if input_string is None: # apparently shlex.split() doesn't like None as its input :)
+ return inputs
+
try:
inputs = shlex.split(input_string)
except ValueError, e:
@@ -243,6 +246,7 @@
if cmd in ['list', None]:
# Munge things to run the repolist command
cmds = self._shlex_split(args)
+
if not cmds:
cmds = ['all']
cmds.insert(0, 'repolist')
More information about the Yum-cvs-commits
mailing list