]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
denc: Fix std::array bound_encode
authorAdam C. Emerson <aemerson@redhat.com>
Tue, 9 Jan 2018 22:09:55 +0000 (17:09 -0500)
committerAdam C. Emerson <aemerson@redhat.com>
Fri, 12 Jan 2018 05:49:01 +0000 (00:49 -0500)
std::arrays are not variable length structures and thus are not
encoded with a length.

Signed-off-by: Adam C. Emerson <aemerson@redhat.com>
src/include/denc.h

index 36ef8b7ae110d1811a480ca09bf5447aa70491b0..1b27f892327aed210134c3b33b76faadd2de6a62 100644 (file)
@@ -1066,7 +1066,6 @@ public:
     if constexpr (traits::bounded) {
       if constexpr (traits::featured) {
         size_t elem_size = 0;
-        p += sizeof(uint32_t);
         if (!s.empty()) {
           denc(*s.begin(), elem_size, f);
           p += elem_size * s.size();