67142b1ff7
e902fa55-force-binary-mode-with-FTP-servers.patch OBS-URL: https://build.opensuse.org/package/show/Virtualization/virt-manager?expand=0&rev=358
20 lines
787 B
Diff
20 lines
787 B
Diff
Subject: urlfetcher: force binary mode with FTP servers (bz #1462838)
|
|
From: Cole Robinson crobinso@redhat.com Thu Aug 17 16:10:46 2017 -0400
|
|
Date: Thu Aug 17 16:10:46 2017 -0400:
|
|
Git: e902fa5550cc09538429b0fa828fb31aa2706d01
|
|
|
|
|
|
diff --git a/virtinst/urlfetcher.py b/virtinst/urlfetcher.py
|
|
index d04c78f..c60c77d 100644
|
|
--- a/virtinst/urlfetcher.py
|
|
+++ b/virtinst/urlfetcher.py
|
|
@@ -224,6 +224,8 @@ class _FTPURLFetcher(_URLFetcher):
|
|
self._ftp = ftplib.FTP()
|
|
self._ftp.connect(parsed.hostname, parsed.port)
|
|
self._ftp.login()
|
|
+ # Force binary mode
|
|
+ self._ftp.voidcmd("TYPE I")
|
|
except Exception as e:
|
|
raise ValueError(_("Opening URL %s failed: %s.") %
|
|
(self.location, str(e)))
|