]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
cls_rgw: fix issue with gc code using the wrong name 26564/head
authorAbhishek Lekshmanan <abhishek@suse.com>
Thu, 14 Mar 2019 21:26:32 +0000 (22:26 +0100)
committerAbhishek Lekshmanan <abhishek@suse.com>
Thu, 14 Mar 2019 21:26:32 +0000 (22:26 +0100)
Also use the correct ptr notation

Signed-off-by: Abhishek Lekshmanan <abhishek@suse.com>
src/cls/rgw/cls_rgw.cc

index 1f57cceeb359d2e40b5bc68e25fc9411693a06c4..43f74178f2bc6b6d4239fc34f9ad24f0343c8d0c 100644 (file)
@@ -757,7 +757,7 @@ static void log_entry(const char *func, const char *str, rgw_bucket_olh_entry *e
 
 template <class T>
 static int read_omap_entry(cls_method_context_t hctx, const std::string& name,
-                           T *entry)
+                           Tentry)
 {
   bufferlist current_entry;
   int rc = cls_cxx_map_get_val(hctx, name, &current_entry);
@@ -776,7 +776,7 @@ static int read_omap_entry(cls_method_context_t hctx, const std::string& name,
 }
 
 template <class T>
-static int read_index_entry(cls_method_context_t hctx, string& name, T *entry)
+static int read_index_entry(cls_method_context_t hctx, string& name, Tentry)
 {
   int ret = read_omap_entry(hctx, name, entry);
   if (ret < 0) {
@@ -3179,7 +3179,7 @@ static int gc_omap_get(cls_method_context_t hctx, int type, const string& key, c
   string index;
   prepend_index_prefix(key, type, &index);
 
-  int ret = read_omap_entry(hctx, key, info);
+  int ret = read_omap_entry(hctx, index, info);
   if (ret < 0)
     return ret;