From 7ebbf17f37890d779ddd8a2faa116c965348f742 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Adrien=20B=C3=A9raud?= <adrien.beraud@savoirfairelinux.com>
Date: Fri, 5 Apr 2019 10:46:41 -0400
Subject: [PATCH] InfoHash: use static size

---
 include/opendht/infohash.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/include/opendht/infohash.h b/include/opendht/infohash.h
index c6952970..e6d979af 100644
--- a/include/opendht/infohash.h
+++ b/include/opendht/infohash.h
@@ -85,7 +85,7 @@ public:
         msgpack_unpack(o);
     }
 
-    constexpr size_t size() const noexcept { return data_.size(); }
+    static constexpr size_t size() noexcept { return N; }
     const uint8_t* data() const { return data_.data(); }
     uint8_t* data() { return data_.data(); }
     iterator begin() { return data_.begin(); }
-- 
GitLab