From: Yehuda Sadeh Date: Fri, 22 Apr 2016 00:24:16 +0000 (-0700) Subject: rgw: check for status >= 0 X-Git-Tag: v10.2.1~44^2~3 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=1d12f82a24f78769bcebb32cb379445e04f35e46;p=ceph.git rgw: check for status >= 0 Fixes: #15565 check only verified that status was > 0, so we ended not updating mtime for the target object. This resulted in a continuous sync of objects. Signed-off-by: Yehuda Sadeh (cherry picked from commit 255f19d9ef964536f2db17f70749f489330262a6) --- diff --git a/src/rgw/rgw_rest_client.cc b/src/rgw/rgw_rest_client.cc index 73cc12999de0..b219e6f15429 100644 --- a/src/rgw/rgw_rest_client.cc +++ b/src/rgw/rgw_rest_client.cc @@ -692,7 +692,7 @@ int RGWRESTStreamRWRequest::get_resource(RGWAccessKey& key, map& int RGWRESTStreamRWRequest::complete(string& etag, real_time *mtime, map& attrs) { set_str_from_headers(out_headers, "ETAG", etag); - if (status > 0 && mtime) { + if (status >= 0 && mtime) { string mtime_str; set_str_from_headers(out_headers, "RGWX_MTIME", mtime_str); if (!mtime_str.empty()) {