21 lines
707 B
Diff
21 lines
707 B
Diff
|
Subject: virtinst: Fix _URLFetcher for reading files
|
||
|
From: Andrew Wong andrew.kw.w@gmail.com Wed Nov 8 01:23:28 2017 -0500
|
||
|
Date: Wed Nov 22 17:26:31 2017 -0500:
|
||
|
Git: f836e47b7053ce8cd83c66728acfb9b0f821bcac
|
||
|
|
||
|
_grabber() is used for both binary and text files.
|
||
|
|
||
|
diff --git a/virtinst/urlfetcher.py b/virtinst/urlfetcher.py
|
||
|
index 5dae424c..1288668a 100644
|
||
|
--- a/virtinst/urlfetcher.py
|
||
|
+++ b/virtinst/urlfetcher.py
|
||
|
@@ -169,7 +169,7 @@ class _URLFetcher(object):
|
||
|
"""
|
||
|
Grab the passed filename from self.location and return it as a string
|
||
|
"""
|
||
|
- fileobj = io.StringIO()
|
||
|
+ fileobj = io.BytesIO()
|
||
|
self._grabURL(filename, fileobj)
|
||
|
return fileobj.getvalue()
|
||
|
|