diff options
Diffstat (limited to 'tdutils')
| -rw-r--r-- | tdutils/td/utils/Ed25519.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/tdutils/td/utils/Ed25519.h b/tdutils/td/utils/Ed25519.h index 3af162537..d3dbd75f5 100644 --- a/tdutils/td/utils/Ed25519.h +++ b/tdutils/td/utils/Ed25519.h @@ -26,7 +26,11 @@ class Ed25519 { PublicKey(const PublicKey &other) : octet_string_(other.octet_string_.copy()) { } PublicKey(PublicKey &&) noexcept = default; - PublicKey &operator=(const PublicKey &) = delete; + PublicKey &operator=(const PublicKey &other) { + CHECK(octet_string_.empty()); + octet_string_ = other.octet_string_.copy(); + return *this; + } PublicKey &operator=(PublicKey &&) noexcept = delete; ~PublicKey() = default; |
