/usr/include/crypto++/filters.h does not compile cleanly in year 2016

Bug #1568360 reported by Jeff Abrahamson
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
libcrypto++ (Ubuntu)
New
Undecided
Unassigned

Bug Description

A minor bug, but clearly a bug since at least 2011:

jeff@starshine:tmp $ echo '#include <filters.h>' > wall.cpp
jeff@starshine:tmp $ g++ -Wall -c wall.cpp -I /usr/include/crypto++/
In file included from /usr/include/crypto++/simple.h:10:0,
                 from /usr/include/crypto++/filters.h:6,
                 from wall.cpp:1:
/usr/include/crypto++/algparam.h: In instantiation of ‘CryptoPP::ConstByteArrayParameter::ConstByteArrayParameter(const T&, bool) [with T = std::__cxx11::basic_string<char>]’:
/usr/include/crypto++/filters.h:793:132: required from here
/usr/include/crypto++/misc.h:59:118: warning: unused variable ‘cryptopp_assert_26’ [-Wunused-variable]
 #define CRYPTOPP_COMPILE_ASSERT_INSTANCE(assertion, instance) static CompileAssert<(assertion)> CRYPTOPP_ASSERT_JOIN(cryptopp_assert_, instance)
                                                                                                                      ^
/usr/include/crypto++/misc.h:62:39: note: in definition of macro ‘CRYPTOPP_DO_ASSERT_JOIN’
 #define CRYPTOPP_DO_ASSERT_JOIN(X, Y) X##Y
                                       ^
/usr/include/crypto++/misc.h:59:97: note: in expansion of macro ‘CRYPTOPP_ASSERT_JOIN’
 #define CRYPTOPP_COMPILE_ASSERT_INSTANCE(assertion, instance) static CompileAssert<(assertion)> CRYPTOPP_ASSERT_JOIN(cryptopp_assert_, instance)
                                                                                                 ^
/usr/include/crypto++/misc.h:55:44: note: in expansion of macro ‘CRYPTOPP_COMPILE_ASSERT_INSTANCE’
 #define CRYPTOPP_COMPILE_ASSERT(assertion) CRYPTOPP_COMPILE_ASSERT_INSTANCE(assertion, __LINE__)
                                            ^
/usr/include/crypto++/algparam.h:26:9: note: in expansion of macro ‘CRYPTOPP_COMPILE_ASSERT’
         CRYPTOPP_COMPILE_ASSERT(sizeof(CPP_TYPENAME T::value_type) == 1);
         ^
In file included from /usr/include/crypto++/filters.h:11:0,
                 from wall.cpp:1:
/usr/include/crypto++/algparam.h: In instantiation of ‘void CryptoPP::AlgorithmParametersTemplate<T>::MoveInto(void*) const [with T = CryptoPP::RandomNumberGenerator*]’:
/usr/include/crypto++/filters.h:808:1: required from here
/usr/include/crypto++/algparam.h:322:35: warning: unused variable ‘p’ [-Wunused-variable]
   AlgorithmParametersTemplate<T>* p = new(buffer) AlgorithmParametersTemplate<T>(*this);
                                   ^
In file included from /usr/include/crypto++/simple.h:10:0,
                 from /usr/include/crypto++/filters.h:6,
                 from wall.cpp:1:
/usr/include/crypto++/misc.h:549:20: warning: ‘std::__cxx11::string CryptoPP::StringNarrow(const wchar_t*, bool)’ defined but not used [-Wunused-function]
 static std::string StringNarrow(const wchar_t *str, bool throwOnError = true)
                    ^
jeff@starshine:tmp $

Of course, it's fine without -Wall.

For history (repeating itself), see also https://bugs.launchpad.net/ubuntu/+source/libcrypto++/+bug/801369

ProblemType: Bug
DistroRelease: Ubuntu 15.10
Package: libcrypto++-dev 5.6.1-8
ProcVersionSignature: Ubuntu 4.2.0-34.39-generic 4.2.8-ckt4
Uname: Linux 4.2.0-34-generic x86_64
NonfreeKernelModules: wl
ApportVersion: 2.19.1-0ubuntu5
Architecture: amd64
CurrentDesktop: i3
Date: Sat Apr 9 21:06:51 2016
Dependencies:
 gcc-5-base 5.2.1-22ubuntu2
 libc6 2.21-0ubuntu4.1
 libcrypto++9v5 5.6.1-8
 libgcc1 1:5.2.1-22ubuntu2
 libstdc++6 5.2.1-22ubuntu2
EcryptfsInUse: Yes
InstallationDate: Installed on 2015-12-17 (114 days ago)
InstallationMedia: Ubuntu 15.04 "Vivid Vervet" - Release amd64 (20150422)
SourcePackage: libcrypto++
UpgradeStatus: Upgraded to wily on 2015-12-17 (114 days ago)

Revision history for this message
Jeff Abrahamson (jeff-purple) wrote :
Revision history for this message
Jeffrey Walton (noloader) wrote :

Crypto++ should now be clean (or mostly clean) at -Wall -Wextra. Recommend closing this issue report.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.