remove svn keywords and use %{SCMURL} in spec file
[bootmanager.git] / source / utils.py
index 89c63d3..02a30cd 100644 (file)
@@ -1,8 +1,5 @@
 #!/usr/bin/python
 #
-# $Id$
-# $URL$
-#
 # Copyright (c) 2003 Intel Corporation
 # All rights reserved.
 #
@@ -135,7 +132,7 @@ def sysexec( cmd, log= None, fsck = False ):
 
     try:
         if cmd.__contains__(">"):
-            prog = subprocess.Popen(shlex.split(cmd), shell=True)
+            prog = subprocess.Popen(cmd, shell=True)
         else:
             prog = subprocess.Popen(shlex.split(cmd), stdout=subprocess.PIPE, stderr=subprocess.PIPE)
     except OSError:
@@ -148,7 +145,8 @@ def sysexec( cmd, log= None, fsck = False ):
         raise BootManagerException, "Interrupted by user"
 
     if log is not None:
-        log.write(stdoutdata)
+        if stdoutdata is not None:
+            log.write(stdoutdata)
 
     returncode = prog.wait()