From 37ccf119a00fdd350a9f03bc35307774740b10b3 Mon Sep 17 00:00:00 2001 From: Peter Jones Date: Wed, 9 Mar 2005 18:41:11 +0000 Subject: take useless syscalls out of ddfile() --- isys/isys.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'isys/isys.py') diff --git a/isys/isys.py b/isys/isys.py index 948571ecc..f7ad38a77 100644 --- a/isys/isys.py +++ b/isys/isys.py @@ -144,9 +144,7 @@ def unlosetup(device): os.close(loop) def ddfile(file, megs, pw = None): - fd = os.open("/dev/zero", os.O_RDONLY); - buf = os.read(fd, 1024 * 256) - os.close(fd) + buf = '\x00' * 1024 * 256 fd = os.open(file, os.O_RDWR | os.O_CREAT) -- cgit