Add gcc10-conversion.patch provide by Red Hat's compiler team

This commit is contained in:
Sérgio M. Basto 2019-09-25 00:53:40 +01:00
parent d08c648de8
commit c3938a10a2
2 changed files with 31 additions and 1 deletions

26
gcc10-conversion.patch Normal file
View File

@ -0,0 +1,26 @@
diff -Nrup a/CPP/Windows/ErrorMsg.cpp b/CPP/Windows/ErrorMsg.cpp
--- a/CPP/Windows/ErrorMsg.cpp 2015-01-18 11:20:28.000000000 -0700
+++ b/CPP/Windows/ErrorMsg.cpp 2019-09-24 13:01:18.887289152 -0600
@@ -14,14 +14,14 @@ UString MyFormatMessage(DWORD errorCode)
AString msg;
switch(errorCode) {
- case ERROR_NO_MORE_FILES : txt = "No more files"; break ;
- case E_NOTIMPL : txt = "E_NOTIMPL"; break ;
- case E_NOINTERFACE : txt = "E_NOINTERFACE"; break ;
- case E_ABORT : txt = "E_ABORT"; break ;
- case E_FAIL : txt = "E_FAIL"; break ;
- case STG_E_INVALIDFUNCTION : txt = "STG_E_INVALIDFUNCTION"; break ;
- case E_OUTOFMEMORY : txt = "E_OUTOFMEMORY"; break ;
- case E_INVALIDARG : txt = "E_INVALIDARG"; break ;
+ case unsigned (ERROR_NO_MORE_FILES) : txt = "No more files"; break ;
+ case unsigned (E_NOTIMPL) : txt = "E_NOTIMPL"; break ;
+ case unsigned (E_NOINTERFACE) : txt = "E_NOINTERFACE"; break ;
+ case unsigned (E_ABORT) : txt = "E_ABORT"; break ;
+ case unsigned (E_FAIL) : txt = "E_FAIL"; break ;
+ case unsigned (STG_E_INVALIDFUNCTION) : txt = "STG_E_INVALIDFUNCTION"; break ;
+ case unsigned (E_OUTOFMEMORY) : txt = "E_OUTOFMEMORY"; break ;
+ case unsigned (E_INVALIDARG) : txt = "E_INVALIDARG"; break ;
case ERROR_DIRECTORY : txt = "Error Directory"; break ;
default:
txt = strerror(errorCode);

View File

@ -7,7 +7,7 @@
Summary: Very high compression ratio file archiver
Name: p7zip
Version: 16.02
Release: 15%{?dist}
Release: 16%{?dist}
# Files under C/Compress/Lzma/ are dual LGPL or CPL
License: LGPLv2 and (LGPLv2+ or CPL)
URL: http://p7zip.sourceforge.net/
@ -28,6 +28,7 @@ Patch6: CVE-2016-9296.patch
Patch7: 05-hardening-flags.patch
Patch10: CVE-2017-17969.patch
Patch11: 14-Fix-g++-warning.patch
Patch12: gcc10-conversion.patch
BuildRequires: gcc
BuildRequires: gcc-c++
@ -172,6 +173,9 @@ make test
%changelog
* Tue Sep 24 2019 Sérgio Basto <sergio@serjux.com> - 16.02-16
- Add gcc10-conversion.patch provide by Red Hat's compiler team
* Thu Jul 25 2019 Fedora Release Engineering <releng@fedoraproject.org> - 16.02-15
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild