Removes the use of O_SYNC on logs #1656

With O_SYNC on open of log files, on systems with slow filesystem random
write performance, there is random activity startup time.
This commit is contained in:
James Cameron 2010-03-09 09:29:30 +11:00 committed by Simon Schampijer
parent 6921bcd67d
commit f8ef93bd21

View File

@ -149,8 +149,7 @@ def open_log_file(activity):
while True:
path = env.get_logs_path('%s-%s.log' % (activity.get_bundle_id(), i))
try:
fd = os.open(path, os.O_EXCL | os.O_CREAT \
| os.O_SYNC | os.O_WRONLY, 0644)
fd = os.open(path, os.O_EXCL | os.O_CREAT | os.O_WRONLY, 0644)
f = os.fdopen(fd, 'w', 0)
return (path, f)
except OSError, e: