From dd7690fc53bc3cd96cd8124542b864958e728b44 Mon Sep 17 00:00:00 2001 From: weiqiaomiao Date: Mon, 27 Jun 2016 16:51:14 +0800 Subject: [PATCH] rgw: fix memory leak in RGWRados::fetch_remote_obj() Signed-off-by: weiqiaomiao --- 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 078fe9cd84c80..3d849ecbc3520 100644 --- a/src/rgw/rgw_rados.cc +++ b/src/rgw/rgw_rados.cc @@ -6663,7 +6663,7 @@ int RGWRados::fetch_remote_obj(RGWObjectCtx& obj_ctx, /* need to get mtime for destination */ ret = get_obj_state(&obj_ctx, dest_obj, &dest_state, NULL); if (ret < 0) - return ret; + goto set_err_state; if (!real_clock::is_zero(dest_state->mtime)) { dest_mtime_weight.init(dest_state);