Cpp: Fix some pedantic warnings

* lang/cpp/src/context.cpp,
lang/cpp/src/context.h (Context::getKeysFromRecipients): Remove
ignored / invalid const qualifier.
* lang/cpp/src/result.h: Don't shadow error function in ctor.
This commit is contained in:
Andre Heinecke 2016-08-17 07:23:05 +02:00
parent 8c09dd9989
commit 64194b0f8d
3 changed files with 4 additions and 4 deletions

View File

@ -1109,7 +1109,7 @@ static gpgme_encrypt_flags_t encryptflags2encryptflags(Context::EncryptionFlags
return static_cast<gpgme_encrypt_flags_t>(result);
}
gpgme_key_t *const Context::getKeysFromRecipients(const std::vector<Key> &recipients)
gpgme_key_t *Context::getKeysFromRecipients(const std::vector<Key> &recipients)
{
if (recipients.empty()) {
return nullptr;

View File

@ -371,7 +371,7 @@ public:
private:
// Helper functions that need to be context because they rely
// on the "Friendlyness" of context to access the gpgme types.
gpgme_key_t *const getKeysFromRecipients(const std::vector<Key> &recipients);
gpgme_key_t *getKeysFromRecipients(const std::vector<Key> &recipients);
private:
Private *const d;

View File

@ -35,8 +35,8 @@ class GPGMEPP_EXPORT Result
{
protected:
explicit Result() : mError() {}
explicit Result(int error) : mError(error) {}
explicit Result(const Error &error) : mError(error) {}
explicit Result(int err) : mError(err) {}
explicit Result(const Error &err) : mError(err) {}
void swap(Result &other)
{