Line 0
Link Here
|
|
|
1 |
The operator< should be const, so it can be applied to const Signatures. |
2 |
This fixes a build failure in security/libkleo. |
3 |
|
4 |
diff --git lang/cpp/src/key.cpp lang/cpp/src/key.cpp |
5 |
index e536d080..7411e9e4 100644 |
6 |
--- lang/cpp/src/key.cpp |
7 |
+++ lang/cpp/src/key.cpp |
8 |
@@ -865,7 +865,7 @@ UserID::Signature::Signature(const shared_gpgme_key_t &k, gpgme_user_id_t u, gpg |
9 |
{ |
10 |
} |
11 |
|
12 |
-bool UserID::Signature::operator<(const Signature &other) |
13 |
+bool UserID::Signature::operator<(const Signature &other) const |
14 |
{ |
15 |
// based on cmp_signodes() in g10/keylist.c |
16 |
|
17 |
diff --git lang/cpp/src/key.h lang/cpp/src/key.h |
18 |
index a7931672..57001a03 100644 |
19 |
--- lang/cpp/src/key.h |
20 |
+++ lang/cpp/src/key.h |
21 |
@@ -468,7 +468,7 @@ public: |
22 |
} |
23 |
|
24 |
/*! Defines a canonical sort order for signatures of the same user ID. */ |
25 |
- bool operator<(const Signature &other); |
26 |
+ bool operator<(const Signature &other) const; |
27 |
|
28 |
bool isNull() const |
29 |
{ |