From 3401ca9b3c4b454dff4115344f80aa61f285ccc9 Mon Sep 17 00:00:00 2001 From: Oz Date: Mon, 23 Oct 2023 19:18:40 +0200 Subject: [PATCH] Remove no_sanitize attributes --- src/internal/formatdetect.cpp | 3 --- src/internal/util.hpp | 3 --- 2 files changed, 6 deletions(-) diff --git a/src/internal/formatdetect.cpp b/src/internal/formatdetect.cpp index bcf2a41e..35670cb3 100644 --- a/src/internal/formatdetect.cpp +++ b/src/internal/formatdetect.cpp @@ -364,9 +364,6 @@ auto read_signature( IInStream* stream, uint32_t size ) noexcept -> uint64_t { } // Note: the left shifting of the signature mask might overflow, but it is intentional, so we suppress the sanitizer. -#if defined(__clang__) && defined(__clang_major__) && (__clang_major__ >= 12) -__attribute__((no_sanitize ("unsigned-shift-base"))) -#endif auto detect_format_from_signature( IInStream* stream ) -> const BitInFormat& { constexpr auto kSignatureSize = 8U; constexpr auto kBaseSignatureMask = 0xFFFFFFFFFFFFFFFFULL; diff --git a/src/internal/util.hpp b/src/internal/util.hpp index b59dc38e..f0bfe199 100644 --- a/src/internal/util.hpp +++ b/src/internal/util.hpp @@ -24,9 +24,6 @@ constexpr inline auto check_overflow( int64_t position, int64_t offset ) noexcep ( ( offset < 0 ) && ( position < ( ( std::numeric_limits< int64_t >::min )() - offset ) ) ); } -#if defined(__clang__) && defined(__clang_major__) && (__clang_major__ >= 4) -__attribute__((no_sanitize ("unsigned-integer-overflow"))) -#endif inline auto seek_to_offset( uint64_t& position, int64_t offset ) noexcept -> HRESULT { // Checking if adding the offset would result in the unsigned wrap around of the current position. if ( offset < 0 ) {