]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
Merge pull request #26358 from smithfarm/wip-37557-luminous
authorYuri Weinstein <yweinste@redhat.com>
Thu, 28 Mar 2019 15:45:34 +0000 (08:45 -0700)
committerGitHub <noreply@github.com>
Thu, 28 Mar 2019 15:45:34 +0000 (08:45 -0700)
luminous: multisite: es sync null versioned object failed because of olh info

Reviewed-by: Abhishek Lekshmanan <abhishek.lekshmanan@gmail.com>
Reviewed-by: Casey Bodley <cbodley@redhat.com>
1  2 
src/rgw/rgw_sync_module_es.cc

index ccb688d7335f28a01d74ef97d72fff62442a161b,0bf2360bac287d8fc4d413b6d3e998236c1ed17f..b5be52413ba62c90704cb70805f18e0fc97916b7
@@@ -454,9 -286,9 +454,9 @@@ struct es_obj_metadata 
          continue;
        }
  
-       if (attr_name.compare(0, sizeof(RGW_ATTR_META_PREFIX) - 1, RGW_ATTR_META_PREFIX) == 0) {
+       if (boost::algorithm::starts_with(attr_name, RGW_ATTR_META_PREFIX)) {
          custom_meta.emplace(attr_name.substr(sizeof(RGW_ATTR_META_PREFIX) - 1),
 -                            string(val.c_str(), (val.length() > 0 ? val.length() - 1 : 0)));
 +                            string(val.c_str(), attr_len(val)));
          continue;
        }