fix the patch for adding uncompressed ppd via CLI

This commit is contained in:
Zdenek Dohnal 2020-10-12 15:10:30 +02:00
parent 2f37664639
commit b80a1ae081
2 changed files with 12 additions and 9 deletions

View File

@ -1,14 +1,14 @@
diff --git a/setup.py b/setup.py
index ba1b519..4f64eed 100755
index 976a42c..3604dd7 100755
--- a/setup.py
+++ b/setup.py
@@ -556,6 +556,9 @@ else: # INTERACTIVE_MODE
@@ -558,6 +558,9 @@ else: # INTERACTIVE_MODE
if file_path.endswith('.gz'):
nickname = gzip.GzipFile(file_path, 'r').read(4096)
+ if sys.version_info[0] > 2:
+ nickname = nickname.decode('utf-8')
+
else:
nickname = open(file_path, 'r').read(4096)
+ if sys.version_info[0] > 2:
+ nickname = nickname.decode('utf-8')
+
try:
desc = nickname_pat.search(nickname).group(1)
except AttributeError:

View File

@ -7,7 +7,7 @@
Summary: HP Linux Imaging and Printing Project
Name: hplip
Version: 3.20.9
Release: 1%{?dist}
Release: 2%{?dist}
License: GPLv2+ and MIT and BSD and IJG and Public Domain and GPLv2+ with exceptions and ISC
Url: https://developers.hp.com/hp-linux-imaging-and-printing
@ -770,6 +770,9 @@ rm -f %{buildroot}%{_sysconfdir}/xdg/autostart/hplip-systray.desktop
%config(noreplace) %{_sysconfdir}/sane.d/dll.d/hpaio
%changelog
* Mon Oct 12 2020 Zdenek Dohnal <zdohnal@redhat.com> - 3.20.9-2
- fix the patch for adding uncompressed ppd via CLI
* Fri Oct 02 2020 Zdenek Dohnal <zdohnal@redhat.com> - 3.20.9-1
- 3.20.9