Changeset 80:9700e45af602 in livinglogic.python.tipimaid

Show
Ignore:
Timestamp:
02/03/09 11:01:41 (10 years ago)
Author:
Walter Doerwald <walter@…>
Branch:
default
Message:

Move retcode handling into the try block.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • liaalh.py

    r79 r80  
    149149            else: 
    150150                retcode = os.system("%s %s" % (self.execute, filename)) 
     151            if retcode != 0: 
     152                sys.stderr.write("Subprocess \"%s %s\" returned error code %s" % (self.execute, filename, retcode)) 
     153                sys.stderr.flush() 
    151154        except OSError, exc: 
    152155            sys.stderr.write("Subprocess \"%s %s\" caused exception %r" % (self.execute, filename, retcode)) 
    153             sys.stderr.flush() 
    154         if retcode != 0: 
    155             sys.stderr.write("Subprocess \"%s %s\" returned error code %s" % (self.execute, filename, retcode)) 
    156156            sys.stderr.flush() 
    157157