Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
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
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
44a118af
Commit
44a118af
authored
Apr 30, 2006
by
Georg Brandl
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Patch #1470976: don't NLST files when retrieving over FTP.
parent
bffb0bc0
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
7 deletions
+0
-7
Lib/urllib.py
Lib/urllib.py
+0
-7
No files found.
Lib/urllib.py
View file @
44a118af
...
...
@@ -856,13 +856,6 @@ class ftpwrapper:
self
.
ftp
.
voidcmd
(
cmd
)
conn
=
None
if
file
and
not
isdir
:
# Use nlst to see if the file exists at all
try
:
self
.
ftp
.
nlst
(
file
)
except
ftplib
.
error_perm
,
reason
:
raise
IOError
,
(
'ftp error'
,
reason
),
sys
.
exc_info
()[
2
]
# Restore the transfer mode!
self
.
ftp
.
voidcmd
(
cmd
)
# Try to retrieve as a file
try
:
cmd
=
'RETR '
+
file
...
...
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