summaryrefslogtreecommitdiffstats
path: root/fsset.py
diff options
context:
space:
mode:
authorMatt Wilson <msw@redhat.com>2001-06-21 23:13:44 +0000
committerMatt Wilson <msw@redhat.com>2001-06-21 23:13:44 +0000
commit7b2529cb17fd1f82e4fbe02af7ccc38553ec97e8 (patch)
tree858ddd9b151fdb78660138306b6e8de3edff95b8 /fsset.py
parentf4d3a36badcade537825c7cce77c706c47762823 (diff)
downloadanaconda-7b2529cb17fd1f82e4fbe02af7ccc38553ec97e8.tar.gz
anaconda-7b2529cb17fd1f82e4fbe02af7ccc38553ec97e8.tar.xz
anaconda-7b2529cb17fd1f82e4fbe02af7ccc38553ec97e8.zip
turn down the syncs
Diffstat (limited to 'fsset.py')
-rw-r--r--fsset.py9
1 files changed, 7 insertions, 2 deletions
diff --git a/fsset.py b/fsset.py
index c52b3fdb3..bb34bb051 100644
--- a/fsset.py
+++ b/fsset.py
@@ -944,6 +944,7 @@ def ext2FormatFilesystem(argList, messageFile, windowCreator, mntpoint):
os.write(fd, s)
num = ''
+ sync = 0
while s:
try:
s = os.read(p[0], 1)
@@ -957,8 +958,12 @@ def ext2FormatFilesystem(argList, messageFile, windowCreator, mntpoint):
else:
if num:
l = string.split(num, '/')
- w and w.set((int(l[0]) * 100) / int(l[1]))
- isys.sync()
+ val = (int(l[0]) * 100) / int(l[1])
+ w and w.set(val)
+ # sync every 10%
+ if sync + 10 < val:
+ isys.sync()
+ sync = val
num = ''
except OSError, args:
(num, str) = args