From 175feb95780fadc039c4a0250845ff5ff8aef4ee Mon Sep 17 00:00:00 2001 From: Danny Al-Gaaf Date: Thu, 1 Aug 2013 00:34:41 +0200 Subject: [PATCH] rgw_rados.cc: fix invalid iterator comparison The iterator should be compared against the end() function of the same iter() from region_conn_map. CID 1058791 (#1 of 1): Invalid iterator comparison (MISMATCHED_ITERATOR) mismatched_comparison: Comparing "iter" from "this->region_conn_map" to "this->zone_conn_map.end()" from "this->zone_conn_map". Signed-off-by: Danny Al-Gaaf --- src/rgw/rgw_rados.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/rgw/rgw_rados.cc b/src/rgw/rgw_rados.cc index aba5cdf0ee27..222b79a7d2ec 100644 --- a/src/rgw/rgw_rados.cc +++ b/src/rgw/rgw_rados.cc @@ -2551,7 +2551,7 @@ int RGWRados::copy_obj(void *ctx, conn = rest_master_conn; } else { map::iterator iter = region_conn_map.find(src_bucket_info.region); - if (iter == zone_conn_map.end()) { + if (iter == region_conn_map.end()) { ldout(cct, 0) << "could not find region connection to region: " << source_zone << dendl; return -ENOENT; } -- 2.47.3