Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Leap:15.4:ARM
upx
0001-Silence-yet-some-more-compilation-warnings...
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File 0001-Silence-yet-some-more-compilation-warnings.patch of Package upx
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 From: "Markus F.X.J. Oberhumer" <markus@oberhumer.com> Date: Sat, 15 May 2021 06:00:50 +0200 Subject: [PATCH] Silence yet some more compilation warnings. Origin: https://github.com/upx/upx-lzma-sdk/commit/c6c2fc49e2ac6f3fc82762c6d3703969274d48de --- src/lzma-sdk/C/7zip/Common/InBuffer.cpp | 14 +++++++------- src/lzma-sdk/C/7zip/Compress/LZMA/LZMADecoder.h | 8 ++++---- src/lzma-sdk/C/Common/MyCom.h | 5 +++-- 3 files changed, 14 insertions(+), 13 deletions(-) diff --git a/src/lzma-sdk/C/7zip/Common/InBuffer.cpp b/src/lzma-sdk/C/7zip/Common/InBuffer.cpp index ae54a53..e26eba2 100644 --- a/src/lzma-sdk/C/7zip/Common/InBuffer.cpp +++ b/src/lzma-sdk/C/7zip/Common/InBuffer.cpp @@ -7,10 +7,10 @@ #include "../../Common/Alloc.h" CInBuffer::CInBuffer(): - _buffer(0), - _bufferLimit(0), - _bufferBase(0), - _stream(0), + _buffer(NULL), + _bufferLimit(NULL), + _bufferBase(NULL), + _stream(NULL), _bufferSize(0) {} @@ -19,18 +19,18 @@ bool CInBuffer::Create(UInt32 bufferSize) const UInt32 kMinBlockSize = 1; if (bufferSize < kMinBlockSize) bufferSize = kMinBlockSize; - if (_bufferBase != 0 && _bufferSize == bufferSize) + if (_bufferBase != NULL && _bufferSize == bufferSize) return true; Free(); _bufferSize = bufferSize; _bufferBase = (Byte *)::MidAlloc(bufferSize); - return (_bufferBase != 0); + return (_bufferBase != NULL); } void CInBuffer::Free() { ::MidFree(_bufferBase); - _bufferBase = 0; + _bufferBase = NULL; } void CInBuffer::SetStream(ISequentialInStream *stream) diff --git a/src/lzma-sdk/C/7zip/Compress/LZMA/LZMADecoder.h b/src/lzma-sdk/C/7zip/Compress/LZMA/LZMADecoder.h index 5b9c95f..a7c4ce3 100644 --- a/src/lzma-sdk/C/7zip/Compress/LZMA/LZMADecoder.h +++ b/src/lzma-sdk/C/7zip/Compress/LZMA/LZMADecoder.h @@ -74,16 +74,16 @@ class CLiteralDecoder int _numPosBits; UInt32 _posMask; public: - CLiteralDecoder(): _coders(0) {} + CLiteralDecoder(): _coders(NULL) {} ~CLiteralDecoder() { Free(); } void Free() { MyFree(_coders); - _coders = 0; + _coders = NULL; } bool Create(int numPosBits, int numPrevBits) { - if (_coders == 0 || (numPosBits + numPrevBits) != + if (_coders == NULL || (numPosBits + numPrevBits) != (_numPrevBits + _numPosBits) ) { Free(); @@ -93,7 +93,7 @@ public: _numPosBits = numPosBits; _posMask = (1 << numPosBits) - 1; _numPrevBits = numPrevBits; - return (_coders != 0); + return (_coders != NULL); } void Init() { diff --git a/src/lzma-sdk/C/Common/MyCom.h b/src/lzma-sdk/C/Common/MyCom.h index b8dbf38..c9fe9cd 100644 --- a/src/lzma-sdk/C/Common/MyCom.h +++ b/src/lzma-sdk/C/Common/MyCom.h @@ -156,8 +156,9 @@ public: #define MY_ADDREF_RELEASE \ STDMETHOD_(ULONG, AddRef)() { return ++__m_RefCount; } \ -STDMETHOD_(ULONG, Release)() { if (--__m_RefCount != 0) \ - return __m_RefCount; delete this; return 0; } +STDMETHOD_(ULONG, Release)() { \ + if (--__m_RefCount != 0) return __m_RefCount; \ + delete this; return 0; } #define MY_UNKNOWN_IMP_SPEC(i) \ MY_QUERYINTERFACE_BEGIN \ -- 2.31.1
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor