Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
slapos.buildout
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
isaak yansane-sisk
slapos.buildout
Commits
9c10b75f
Commit
9c10b75f
authored
Aug 24, 2011
by
Łukasz Nowak
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
shutil.copyfileobj has default buffer.
parent
f6356def
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
2 deletions
+1
-2
src/zc/buildout/networkcache.py
src/zc/buildout/networkcache.py
+1
-2
No files found.
src/zc/buildout/networkcache.py
View file @
9c10b75f
...
@@ -80,10 +80,9 @@ def download_network_cached(dir_url, cache_url, path, url, logger,
...
@@ -80,10 +80,9 @@ def download_network_cached(dir_url, cache_url, path, url, logger,
signature_certificate_file_list
=
signature_certificate_file_list
)
signature_certificate_file_list
=
signature_certificate_file_list
)
file_descriptor
=
nc
.
select
(
directory_key
)
file_descriptor
=
nc
.
select
(
directory_key
)
buffer_size
=
min
(
1024
,
os
.
path
.
getsize
(
file_descriptor
.
name
))
f
=
open
(
path
,
'w+b'
)
f
=
open
(
path
,
'w+b'
)
try
:
try
:
shutil
.
copyfileobj
(
file_descriptor
,
f
,
buffer_size
)
shutil
.
copyfileobj
(
file_descriptor
,
f
)
finally
:
finally
:
f
.
close
()
f
.
close
()
file_descriptor
.
close
()
file_descriptor
.
close
()
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment