https://gcc.gnu.org/bugzilla/show_bug.cgi?id=106568

--- Comment #22 from Jonathan Wakely <redi at gcc dot gnu.org> ---
Created attachment 57344
  --> https://gcc.gnu.org/bugzilla/attachment.cgi?id=57344&action=edit
Gzipped preprocessed source

With -O2 -fsantiize=unreachable this prints an error:

pubkey.h:2209:32: runtime error: execution reached an unreachable program point

That happens from the constructor at validat9.cpp:455 

#0 
CryptoPP::PK_FinalTemplate<CryptoPP::DL_VerifierImpl<CryptoPP::DL_SignatureSchemeOptions<CryptoPP::DL_SS<CryptoPP::DL_Keys_ECGDSA<CryptoPP::ECP>,
CryptoPP::DL_Algorithm_ECGDSA<CryptoPP::ECP>,
CryptoPP::DL_SignatureMessageEncodingMethod_DSA, CryptoPP::SHA1, int>,
CryptoPP::DL_Keys_ECGDSA<CryptoPP::ECP>,
CryptoPP::DL_Algorithm_ECGDSA<CryptoPP::ECP>,
CryptoPP::DL_SignatureMessageEncodingMethod_DSA, CryptoPP::SHA1> >
>::PK_FinalTemplate (algorithm=..., this=0x7fffffffc7d0) at
/tmp/cryptopp/cryptlib.h:2626
#1  CryptoPP::Test::ValidateECGDSA (thorough=thorough@entry=true) at
validat9.cpp:455
#2  0x000000000043448f in CryptoPP::Test::Validate (alg=<optimized out>,
thorough=thorough@entry=true) at test.cpp:995
#3  0x000000000043a303 in CryptoPP::Test::scoped_main (argc=3,
argv=0x7fffffffd6b8) at test.cpp:401
#4  0x000000000043aaf3 in main (argc=<optimized out>, argv=<optimized out>) at
test.cpp:1094


I don't see anything obviously wrong with the code.

Reply via email to