1
0
mirror of https://github.com/libretro/Lakka-LibreELEC.git synced 2024-11-24 16:06:19 +00:00
Lakka-LibreELEC/packages/compress/p7zip/patches/p7zip-0501-change-numMethods-from-bool-to-unsigned.patch
2022-04-11 12:42:41 +00:00

35 lines
1.4 KiB
Diff

From 0820ef4b9238c1e39ae5bda32cc08cce3fd3ce89 Mon Sep 17 00:00:00 2001
From: Nisha Parrakat <Nisha.Parrakat@kpit.com>
Date: Wed, 26 May 2021 19:59:28 +0000
Subject: [PATCH] fixes the below error
| ../../../../CPP/7zip/Archive/Wim/WimHandler.cpp: In member function 'virtual LONG NArchive::NWim::CHandler::GetArchiveProperty(PROPID, PROPVARIANT*)':
| ../../../../CPP/7zip/Archive/Wim/WimHandler.cpp:308:11: error: use of an operand of type 'bool' in 'operator++' is forbidden in C++17
| 308 | numMethods++;
| | ^~~~~~~~~~
| ../../../../CPP/7zip/Archive/Wim/WimHandler.cpp:318:9: error: use of an operand of type 'bool' in 'operator++' is forbidden in C++17
| 318 | numMethods++;
use unsigned instead of bool
Signed-off-by: Nisha Parrakat <Nisha.Parrakat@kpit.com>
Upstream-Status: Pending
---
CPP/7zip/Archive/Wim/WimHandler.cpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/CPP/7zip/Archive/Wim/WimHandler.cpp b/CPP/7zip/Archive/Wim/WimHandler.cpp
index 27d3298..4ff5cfe 100644
--- a/CPP/7zip/Archive/Wim/WimHandler.cpp
+++ b/CPP/7zip/Archive/Wim/WimHandler.cpp
@@ -298,7 +298,7 @@ STDMETHODIMP CHandler::GetArchiveProperty(PROPID propID, PROPVARIANT *value)
AString res;
- bool numMethods = 0;
+ unsigned numMethods = 0;
for (unsigned i = 0; i < ARRAY_SIZE(k_Methods); i++)
{
if (methodMask & ((UInt32)1 << i))