weidai11/cryptopp

Warning in esign.cpp with 8.9.0 and gcc-14.1

vgfl opened this issue · 0 comments

vgfl commented

Maybe already reported, just FYI.
With stringop-overflow warning enabled, I get one (only one) warning when building 8.9.0:

esign.cpp: In member function ‘virtual void CryptoPP::InvertibleESIGNFunction::GenerateRandom(CryptoPP::RandomNumberGenerator&, const CryptoPP::NameValuePairs&)’:
esign.cpp:115:28: warning: ‘void* memcpy(void*, const void*, size_t)’ specified bound 18446744073709551612 exceeds maximum object size 9223372036854775807 [-Wstringop-overflow=]
115 | std::memcpy(seed + 4, seedParam.begin(), seedParam.size());
| ~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
esign.cpp:115:28: warning: ‘void* memcpy(void*, const void*, size_t)’ specified bound 18446744073709551612 exceeds maximum object size 9223372036854775807 [-Wstringop-overflow=]

Thanks!
Vincent