Flush log file output to avoid slow buffering
This commit is contained in:
committed by
Brian O'Connor
parent
20005f5bbc
commit
662f2447e3
@@ -71,6 +71,7 @@ isoURLs = {
|
|||||||
'ubuntu-13.10-server-amd64.iso',
|
'ubuntu-13.10-server-amd64.iso',
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
LogStartTime = time()
|
LogStartTime = time()
|
||||||
LogFile = None
|
LogFile = None
|
||||||
|
|
||||||
@@ -91,6 +92,7 @@ def log( *args, **kwargs ):
|
|||||||
if cr:
|
if cr:
|
||||||
output += '\n'
|
output += '\n'
|
||||||
LogFile.write( output )
|
LogFile.write( output )
|
||||||
|
LogFile.flush()
|
||||||
|
|
||||||
|
|
||||||
def run( cmd, **kwargs ):
|
def run( cmd, **kwargs ):
|
||||||
|
|||||||
Reference in New Issue
Block a user